Painfully large errors with silly GADT instances
If (for whatever reason) you decide to ask GHC to derive (using StandaloneDeriving) silly instances for GADTs, like maybe Ord on a GADT that refines its parameters to incompatible types for different constructors, the automatic deriving mechanism fails with massive errors. The attached file gives me 301 lines of errors in GHCi, as it seems to print all the generated code, and the generated code increases in size with the number of constructors of the datatype. I have a large GADT in a project of mine with a couple hundred constructors, and it gave me over 8000 lines of errors.
Trac metadata
Trac field | Value |
---|---|
Version | 6.12.3 |
Type | Bug |
TypeOfFailure | OtherFailure |
Priority | normal |
Resolution | Unresolved |
Component | Compiler |
Test case | |
Differential revisions | |
BlockedBy | |
Related | |
Blocking | |
CC | |
Operating system | |
Architecture |