Why exceptions for error handling is so important

deadalnix via Digitalmars-d digitalmars-d at puremagic.com
Tue Jan 13 17:38:46 PST 2015


On Wednesday, 14 January 2015 at 00:40:10 UTC, Meta wrote:
> On Wednesday, 14 January 2015 at 00:38:21 UTC, Walter Bright 
> wrote:
>> On 1/11/2015 2:48 AM, Walter Bright wrote:
>>> However, if exceptions are thrown for errors instead, the 
>>> programmer has to
>>> deliberately add code if he wishes to ignore the error.
>>
>> Interesting that this article just appeared:
>>
>>  https://blog.golang.org/errors-are-values
>>
>> by Rob Pike on error handling in Go. He concludes with:
>>
>>  "But remember: Whatever you do, always check your errors!"
>>
>> Which sums up why exceptions are better!
>
> But checked exceptions are definitely not.

http://www.artima.com/intv/handcuffs.html

The best sum up of checked exception you'll find.


More information about the Digitalmars-d mailing list