Unclear warning message: Attempting to re-export hidden constructors
Just stumbled upon this after changing a type def to a data def:
Foo.hs:
module Foo (Foo) where
data Foo = Bar | Baz
Bar.hs:
module Bar (Foo.Foo(..)) where
import Foo
Bar.hs:1:12:
Warning: The export item `Foo(..)'
suggests that `Foo' has constructors or class methods,
but it has none
- ..while it actually has constructors.
I think it should say "The export item 'Foo(..)' suggests that 'Foo' has visible constructors or class methods, but it has none", or something even more specific to the re-export case.
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 | |
Operating system | |
Architecture |