Why exceptions for error handling is so important

Walter Bright via Digitalmars-d digitalmars-d at puremagic.com
Mon Jan 12 13:03:25 PST 2015


On 1/12/2015 10:11 AM, "Ola Fosheim =?UTF-8?B?R3LDuHN0YWQi?= 
<ola.fosheim.grostad+dlang at gmail.com>" wrote:
> There are plenty of situations where exceptions used for retries is the most
> sensible solution. Heck, that's even how x86 floating point exceptions work.
> There are plenty of situations where returning state with exceptions makes the
> most sense, e.g. a web service request handler.

I've never encountered any IEEE FP code that ever, and I mean ever, checked the 
'exception' sticky flag that IEEE operations require.

Outside of a FP test suite, that is.

Nobody has ever turned on the FP hardware exception faults, either.

Bringing up IEEE 754 FP exceptions as an example of it being "done right" when 
it is a complete failure severely damages your case.


More information about the Digitalmars-d mailing list