> I notice that Prelude.catch and Exception.catch behave 
> differently, even 
> though they both have the same type signature (and name). 
> Exception.catch 
> catches exceptions that Prelude.catch does not.

Prelude.catch catches IO exceptions only, because this is what the
Haskell report specifies.  i.e. the meaning of

        Prelude.catch undefined (\e -> return 42)

should be undefined rather than 'return 42'.  We can't change the
meaning of Prelude.catch without deviating from Haskell 98.  The idea is
that if you want to use Exceptions in their full glory, you:

        import Prelude hiding (catch)
        import Exception

or (my favourite)

        import qualified Exception

Cheers,
        Simon
_______________________________________________
Glasgow-haskell-users mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-users

Reply via email to