#2112: Bad error message for malformed GADTs
------------------------+---------------------------------------------------
Reporter: tim | Owner:
Type: bug | Status: new
Priority: normal | Component: Compiler (Type checker)
Version: 6.8.1 | Severity: minor
Keywords: | Testcase:
Architecture: Unknown | Os: Unknown
------------------------+---------------------------------------------------
Compiling the following code:
{{{
data Foo a where
Bar :: a -> a
}}}
results in the following error message:
{{{
$ ghc-6.8.1 gadt.hs -XGADTs
gadt.hs:5:3:
Malformed constructor result type: a
In the result type of a data constructor: a
In the data type declaration for `Foo'
$
}}}
It would be nice if the error message mentioned the name of the offending
data constructor ({{{Bar}}} in this case) -- since there might be more
than one.
--
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/2112>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler_______________________________________________
Glasgow-haskell-bugs mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs