[Haskell-cafe] Warnings for unhandled exceptions
Brandon Allbery
allbery.b at gmail.com
Tue Sep 9 13:55:45 UTC 2014
On Tue, Sep 9, 2014 at 8:38 AM, Henk-Jan van Tuyl <hjgtuyl at chello.nl> wrote:
> It would be useful if the compiler gave a warning for each type of
> exception, for each expression, that is not handled by the program.
A problem with this idea is that some exceptions can be potentially thrown
by any expression at any time, based solely on things external to the
program, compiler or runtime. Only software exceptions can reliably be
handled this way --- and those arguably should not be implemented as
exceptions, but as e.g. Maybe/Either/etc. (Floating point exceptions are,
as usual for IEEE floating point, a weird corner case.)
--
brandon s allbery kf8nh sine nomine associates
allbery.b at gmail.com ballbery at sinenomine.net
unix, openafs, kerberos, infrastructure, xmonad http://sinenomine.net
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.haskell.org/pipermail/haskell-cafe/attachments/20140909/813ea9f1/attachment.html>
More information about the Haskell-Cafe
mailing list