[Haskell] Pattern Matching with rank-2 types
simonpj at microsoft.com
Mon Jan 23 06:43:20 EST 2006
Yes, I changed this some time ago. Handling polymorphic subsumption
when matching patterns just turned to be a lot of hassle, with little
obvious payoff. Types in patterns must now match exactly.
I could conceivably back-pedal on this, but you are the first person to
even notice the change (or at least to comment on it).
| -----Original Message-----
| From: haskell-bounces at haskell.org [mailto:haskell-bounces at haskell.org]
On Behalf Of Bruno Oliveira
| Sent: 21 January 2006 18:44
| To: Haskell Mailing List
| Subject: [Haskell] Pattern Matching with rank-2 types
| The following function is a valid function in ghc6.2.2:
| > func :: (forall a . [a]) -> [b]
| > func  = 
| However, in ghc6.4.1 it does not work anymore:
| Couldn't match `forall a. [a]' against `[a]'
| When checking the pattern: 
| In the definition of `func': func  = 
| Is this supposed to happen?
| Haskell mailing list
| Haskell at haskell.org
More information about the Haskell