Sun, 16 Sep 2001 16:28:01 +0800 (GMT-8), Saswat Anand <[EMAIL PROTECTED]> pisze:
> trickyFun fun = let x = fun (2::Int) -----------(1)
> y = fun 'c' -----------(2)
> in "tricky"
It can't be done this way in standard Haskell.
In GHC and Hugs you can use local universal quantifaction
by writing explicit type signature:
trickyFun :: (forall a. X a => a -> b) -> String
GHC needs to be run with -fglasgow-exts, Hugs needs -98.
GHC user's guide describes some limitations, e.g. trickyFun must
always be directly applied to an argument.
--
__("< Marcin Kowalczyk * [EMAIL PROTECTED] http://qrczak.ids.net.pl/
\__/
^^ SYGNATURA ZASTĘPCZA
QRCZAK
_______________________________________________
Haskell mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/haskell