HEAD (7.5.20120421) requires RankNTypes for a rank-2 type
While building syb with HEAD, Ian reported that he needed to use RankNTypes instead of Rank2Types. I minimized the problem to:
{-# LANGUAGE Rank2Types #-}
module Rank2 where
f :: (forall a. a -> (forall b. b)) -> c
f = undefined
g :: (forall a b. a -> b) -> c
g = undefined
- 4 accepts both
fandg. HEAD complains on the signature off:
Illegal polymorphic or qualified type: forall b. b
Perhaps you intended to use -XRankNTypes or -XRank2Types
In the type signature for `f':
f :: (forall a. a -> (forall b. b)) -> c
It doesn't complain about g, but I think the signatures are equivalent. Ian further reports that the change in behavior seems to have occurred after 7.5.20120401.
Trac metadata
| Trac field | Value |
|---|---|
| Version | 7.5 |
| Type | Bug |
| TypeOfFailure | OtherFailure |
| Priority | normal |
| Resolution | Unresolved |
| Component | Compiler |
| Test case | |
| Differential revisions | |
| BlockedBy | |
| Related | |
| Blocking | |
| CC | |
| Operating system | |
| Architecture |