PartialTypeSignatures mishandles type variables that begin with an underscore
The following GHCi exchange was reported here (you need not follow the link to understand this ticket, though).
Prelude Language.Haskell.TH> runQ [d|foo :: forall _a . _a -> _a;foo x = x|]
[SigD foo_6 (ForallT [PlainTV _a_5] [] (AppT (AppT ArrowT (WildCardT (Just _a_5))) (WildCardT (Just _a_5)))),FunD foo_6 [Clause [VarP x_7] (NormalB (VarE x_7)) []]]
The problem is that the quoted expression uses no wildcards, yet the TH output does. That quoted expression just uses a type variable that begins with an underscore. Such an expression was allowed in Haskell long before wildcards.
Trac metadata
Trac field | Value |
---|---|
Version | 7.10.2 |
Type | Bug |
TypeOfFailure | OtherFailure |
Priority | normal |
Resolution | Unresolved |
Component | Template Haskell |
Test case | |
Differential revisions | |
BlockedBy | |
Related | |
Blocking | |
CC | |
Operating system | |
Architecture |