Changes between Version 37 and Version 38 of TypeFunctionsTypeChecking


Ignore:
Timestamp:
Sep 14, 2006 12:33:17 AM (8 years ago)
Author:
chak
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • TypeFunctionsTypeChecking

    v37 v38  
    9393=== Representation of equality axioms === 
    9494 
     95---- 
     96'''Change of plans:''' The principle representation of an indexed type synonym will actually be a specially tagged version of the `SynTyCon` variant of `TyCon.TyCon` (it also has a parent, like in the data case).  We won't have an `InstInfo` for family instances, but we maintain family instance environments similar to class instance environments (using the `FamInstEnv.FamInst` type).  Eventually, this will also contain a rough match for indexed types plus a reference to the full `TyCon` representation. 
     97---- 
     98 
    9599Type functions have a number of properties in common with class instances; in particular, they require a machinery for matching type patterns against types, as instance heads do during context simplification.  Hence, we probably want some structure similar to `InstEnv.Instance` for type functions - for instances this is maintained in the field `iSpec` of `TcEnv.InstInfo` (for type functions we don't need anything like `iBinds` as they are pure type-level entities).  If possible, it would be ideal if we can reuse (or generalise) some of the matching machinery for instance heads. 
    96100