algebraic data types can be extended by data instance declarations
The following program is accepted by GHC:
{-# LANGUAGE TypeFamilies #-}
data T a = C
data instance T Int = CInt
data instance T Bool = CBool
I think, it shouldn’t.
Trac metadata
Trac field | Value |
---|---|
Version | 6.10.1 |
Type | Bug |
TypeOfFailure | OtherFailure |
Priority | normal |
Resolution | Unresolved |
Component | Compiler |
Test case | |
Differential revisions | |
BlockedBy | |
Related | |
Blocking | |
CC | g9ks157k@acme.softbase.org |
Operating system | |
Architecture |