News for hackers. Stuff that matters.
Re:Isaacs: try/catch is an anti-pattern by dasil003 on Monday November 14, 2011 @12:16PM (#3234765)
Just because you think a certain error will never happen for the lifetime of a program doesn't mean that not explicitly handling it is equally robust.
Re:Isaacs: try/catch is an anti-pattern by eftpotrm on Monday November 14, 2011 @12:57PM (#3234923)
No, I agree, but there's a cost/benefit calculation to be done. Plus it's not like the try...catch solution that doesn't explicitly handle the error will blow up and destroy everything; if the program is properly designed it should merely degrade onto the path of general handling, log the failure and halt whatever was being done.