[Haskell-cafe] MPTCs and rigid variables

David House dmhouse at gmail.com
Sat Mar 3 09:50:08 EST 2007


class Foo a b | a -> b
instance Foo Int String
bar :: Foo Int b => b
bar = "rargh"

Is there any reason why that shouldn't work? GHC gives one of its
silly "b is a rigid variable" errors (aside: that's a really confusing
error; I'd prefer something like Hugs's "Infered type is not general
enough").

-- 
-David House, dmhouse at gmail.com


More information about the Haskell-Cafe mailing list