Hi,
I noticed something odd yesterday. I had a function of this type:
divByGeneric :: (Integral a, MonadError (DivByError a) m) =>
a -> [a] -> m [a]
If I left off the type signature, ghci (with no command-line parameters)
would load the file just fine, and :t would give this same type back. But
if I put the type signature in there -- even an exact cut and paste from
ghci's :t -- it would complain that it needs -XFlexibleContexts.
It seems odd to me that ghci can infer a type that is illegal for the way it
was run. Thoughts?
This is GHC 6.8.2, BTW.
-- John
_______________________________________________
Haskell-Cafe mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/haskell-cafe