Changes between Version 42 and Version 43 of DataParallel/ClosureConversion/ClassLess


Ignore:
Timestamp:
May 1, 2007 5:15:11 AM (8 years ago)
Author:
chak
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • DataParallel/ClosureConversion/ClassLess

    v42 v43  
    3232==== Preliminaries ====
    3333
    34 The alternatives of `TyCon.TyCon` get a new field `tyConCC :: StatusCC TyCon`.  This field is `NoCC` for data constructors for which we have no conversion and `ConvCC T_CC` if we have a conversion, where the converted declaration `T_CC` may coincide with `T`.  In the latter case, there is also ''conversion constructor'' `isoT` between values inhabitating types formed from the original and converted constructor.  The type of these functions is as follows:
    35 {{{
    36 isoTy (T::k1->..->kn->*) = forall _1 .. _n _1_CC .. _n_CC.
    37   isoTy (_1::k1) -> .. -> isoTy (_n::kn) ->
    38   (C _1 .. _n :<->: C_CC _1_CC .. _n_CC)
    39 }}}
    40 (The type variables beginning with underscores are bound here; we add one underscore for each level of kinding.)
     34The alternatives of `TyCon.TyCon` get a new field `tyConCC :: StatusCC TyCon`.  This field is `NoCC` for data constructors for which we have no conversion and `ConvCC T_CC` if we have a conversion, where the converted declaration `T_CC` may coincide with `T`.  In the latter case, there is also a ''conversion constructor'' `isoT` between values inhabitating types formed from the original and converted constructor.  The type of a conversion constructor is determined by the kind of the converted type, as follows:
     35{{{
     36isoTy (t::k1->k2) = forall a a_CC.
     37                      isoTy (a::k1) -> isoTy (t a::k2)
     38isoTy (t::*)      = t :<->: t^
     39}}}
     40where type conversion `t^` is defined below.
    4141
    4242As an example, consider
     
    187187T^            = T_CC , if tyConCC T == ConvCC T_CC
    188188              = T    , otherwise
    189 a^            = a
     189a^            = a_CC
    190190(t1 -> t2)^   = t1 -> t2   , if kindOf t1 == #
    191191                             or kindOf t2 == #