Hello haskell-prime,
about limiting variable usage inside a function to some interface - it
is possible, although is not pleasant :)
{-# OPTIONS_GHC -fglasgow-exts #-}
main = do return "xx" >>= ((\x -> print x) :: Show a => a -> IO ())
main2 = do return "xx" >>= (\(x:: (forall a . (Show a) => a)) -> print x)
main3 = do (x :: forall a . Show a => a) <- return "xx"
print x
in this module, only "main" compiles ok
--
Best regards,
Bulat mailto:[EMAIL PROTECTED]
_______________________________________________
Haskell-prime mailing list
[email protected]
http://haskell.org/mailman/listinfo/haskell-prime