
20 Mar
2013
20 Mar
'13
4:58 a.m.
I'm curious as to why GHC doesn't accept the following (contrived) module: {-# LANGUAGE ImplicitParams, RankNTypes #-} f :: (?g :: (forall a . a -> a)) => a -> a f = ?g The error message is: Illegal polymorphic or qualified type: forall a. a -> a In the type signature for `f': f :: ?g :: (forall a. a -> a) => a -> a It's not a big deal since one can wrap the polymorphism in a newtype, but it's somewhat unexpected. Roman