News for hackers. Stuff that matters.
Re:Exceptions or return codes? by russell on Thursday January 29, 2009 @06:22PM (#457344)
The blog references Spolsky who has marked it expired. Perhaps he has changed his mind.

Problems with error codes:

Too easy to ignore.

Errors and normal return codes get mixed.

Often difficult to pick a distinguished error value, 0, -1?

Problems with exceptions:

Too easy to ignore. How often do you find empty exceptions?

Too many types of exceptions, The Java libraries are particularly guilty of this.

Adding a checked exception can break code all over the universe.

There are no comments on this comment yet.