in reply to Re: Re (tilly) 7: out of loop
in thread out of loop
That said, I think we all have seen elaborate and stupid error handling. Error handling - like everythingthing else in programming - is not an ideal good in and of itself. It serves a goal. That goal is that if your program does not do what you want, that it will let you know that with enough useful information that you can fix the problem. If you are reporting non-errors, or failing to report real ones, or failing to be useful - all are bad.
It is important because code is inherently buggy. A claim that I have heard is that there is an average of one bug per 10 lines written. Dunno if that is true. (I always suspect claims with conveniently round numbers in them.) But certainly the real number is very high. Your error handling is not where you want those bugs to be. Therefore you make your scheme very simple, and concentrate on real errors.
One of which, I guarantee you, is going to be the failure to open a file you expected to be able to open...
|
|---|