j
k
j a
j l
Kim-Ee Yeoh writes:
data Foo a where Foo :: Eq a => a -> Foo a is equivalent to data Foo a = Eq a => Foo a but is different from data Eq a => Foo a = Foo a
data Foo a where Foo :: Eq a => a -> Foo a
is equivalent to
data Foo a = Eq a => Foo a
but is different from
data Eq a => Foo a = Foo a
... and nothing in GADTs does what one would naively expect the last declaration to do.
Back to the thread
Back to the list