Updated: there is now a page on this site dedicated to this topic.
About 8 months ago, I was going to a big blog post on error handling in programs. I think its an interesting and practical topic. Proper code requires lots of good error handling. I was trying to understand which systems work the best and I couldn’t really come to a conclusion myself.
So before going on, what is the best system for error handling that you have used?
How does language X, Y, or Z handle it. (C, Smalltalk, Objective-C, Forth, Common Lisp, Io, Erlang Haskell, Ruby, Python, PHP, Java). What about OS level systems or windowing systems?
What is the best system that you have used?
Just to get things started. I’ve found that a lot of the C style systems to be too laisez faire. On the other end of the spectrum, putting a try / catch/except handler for every possibility doesn’t make me feel too good either. Then you have things like PHP which toss errors if you use an ‘@’ symbol on the function call.
Anything innovative out there?