GADTs Syntax Infelicity with {;}
GHC doesn't like semicolons at the end of GADT constructor lists:
data Foo a where
{
BoolFoo :: Bool -> Foo Bool;
IntFoo :: Int -> Foo Int;
}
Workaround: remove the last semicolon:
data Foo a where
{
BoolFoo :: Bool -> Foo Bool;
IntFoo :: Int -> Foo Int
}
Trac metadata
Trac field |
Value |
Version |
6.4 |
Type |
Bug |
TypeOfFailure |
OtherFailure |
Priority |
normal |
Resolution |
ResolvedFixed |
Component |
Compiler (Parser) |
Test case |
|
Differential revisions |
|
BlockedBy |
|
Related |
|
Blocking |
|
CC |
|
Operating system |
|
Architecture |
|