Proposal: Deprecate and remove Prelude.catch and System.IO.Error.{catch, try}
Bas van Dijk
v.dijk.bas at gmail.com
Mon Dec 27 14:29:04 CET 2010
On Mon, Dec 27, 2010 at 1:36 PM, Ian Lynagh <igloo at earth.li> 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.
>
> These exports are annoying for people who want to use the modern
> exception handling functions in Control.Exception, as you need to
> explicitly either import the Prelude with catch hidden, or give the
> module of the function you want to use.
>
> They may also be confusing for beginners, who may not expect to have to
> use anything other than the catch function in the default scope to catch
> all exceptions.
>
> I believe these functions are only there for historical reasons, and are
> old cruft that we should tidy up, so I propose that in the base package
> that comes with GHC 7.2 we deprecate these old functions, and in 7.4 we
> remove them.
>
>
> Suggested deadline: 24 Jan 2011.
>
>
> Thanks
> Ian
>
>
> _______________________________________________
> Libraries mailing list
> Libraries at haskell.org
> http://www.haskell.org/mailman/listinfo/libraries
>
+1
It would also be nice to deprecate ioError in favour of the more
general throwIO.
Bas
More information about the Libraries
mailing list