Jonathan Ellis wrote:
Probably because there usually really isn't anything useful you can
_do_ in such cases.  If my wireless goes down mid-transfer, there's
not a whole lot the app can do besides put up a "sorry, you're hosed"
dialog.  So having the compiler make me add "throws
YouAreHosedException" is just more boilerplate.

I liked them because the compiler would tell me what errors I had to handle, so I could figure it out without having to read some (possibly outdated) document listing return codes. Then, if a library author added a new error condition that I needed to handle, the compiler would force me to do it. The fact that most developers don't handle them *well* doesn't mean that the concept is flawed.

I agree that there are flagrant misuses of checked exceptions where you have to catch a dozen exceptions just to open an SQL database connection, for example, but it's good to know that the compiler can at least tell you if you're not catching them when you should be.

--Dave

/*
PLUG: http://plug.org, #utah on irc.freenode.net
Unsubscribe: http://plug.org/mailman/options/plug
Don't fear the penguin.
*/

Reply via email to