Changes between Version 7 and Version 8 of GhcKinds/KindPolymorphism


Ignore:
Timestamp:
Aug 31, 2011 1:32:38 PM (3 years ago)
Author:
simonpj
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • GhcKinds/KindPolymorphism

    v7 v8  
    8181 
    8282{{{ 
    83 data T1 s as where                         -- (* -> *) -> [*] -> * 
    84   Foo :: s a -> T1 s as -> T1 s (a ': as)  -- forall (s :: * -> *) (a :: *) (as :: [*]). the same 
     83data T1 s as where                          -- forall k. (k -> *) -> [k] -> * 
     84  Foo1 :: s a -> T1 s as -> T1 s (a ': as)  -- forall k (s :: k -> *) (a :: k) (as :: [k]).  
     85                                            --   s a -> T1 k s as -> T1 k s ((':) k a as) 
     86    -- Note that s,a do not scope over the declaration of Foo 
    8587 
    86 data T1 s (as :: [k]) where                -- forall k. (k -> *) -> [k] -> * 
    87   Foo : s a -> T1 s as -> T1 s (a ': as)   -- forall k (s :: k -> *) (a :: k) (as :: [k]). the same where `T1' becomes `T1 k' 
     88data T2 s (as :: [k]) where                 -- Same as T1 
     89  Foo2 : s a -> T1 s as -> T1 s (a ': as)   -- Same as Foo1 
     90    -- Note that s,as,k do not scope over the declaration of Foo 
    8891}}} 
    8992