Proposal: Deprecate and remove Prelude.catch and System.IO.Error.{catch,try}

Henning Thielemann lemming at henning-thielemann.de
Mon Dec 27 14:37:58 CET 2010


On Mon, 27 Dec 2010, Ian Lynagh wrote:

>
> Hi all,
>
>    Deprecate and remove Prelude.catch and System.IO.Error.{catch,try}
>    http://hackage.haskell.org/trac/ghc/ticket/4865
>
> Prelude and System.IO.Error both export an old version of catch, which
> only catches IOError's, and System.IO.Error additionally exports try
> with the same problem.

This would mean, that Control.Exception.catch remains, that catches also 
the non-exception "undefined". (I don't like to start a new thread about 
what to name exception and what error and what names are more appropriate, 
but I think that many people agree, that there is a fundamental difference 
between 'throw' and 'error'.) Ok, changing Control.Exception.catch should 
be a different ticket. After all I think that current exception handling 
in Control.Exception is only a temporary solution until we have a stable 
system with explicit exception lists encoded in types. Thus removing one 
broken temporary solution (Prelude.catch) in order to force people to use 
the other broken temporary solution (Control.Exception.catch) sounds not 
good for me.



More information about the Libraries mailing list