[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

RE: Python or Perl for a Debian maintainance project?

Andrew Suffield wrote:
> On Sun, Feb 15, 2004 at 09:43:23PM +0100, Matthias Urlichs wrote:
> > Every error whatsoever throws an exception. That's far better from a
> > quality POV than to check the error return of
> > _every_single_statement_, because (a) nobody actually programs that
> > way, and (b) if you actually do program that way your code will be
> > twice as long and ten times as unreadable.
> However, it results in code that throws exceptions to the user rather
> than useful error messages, which is amateurish. The user should never
> see an exception unless there is a bug in your code; errors from the
> system should be handled properly. This *does* make your code twice as
> long, but it will not make it any less readable if you do it
> right. Failing to do it is like failing to test your code before
> releasing it, or trusting data read from the network - it is not
> something that has any place in a serious program.

That's an invalid conclusion.  In every language that supports exceptions, you can very well have a global exception handler that catches any uncaught exceptions and presents them to the user in a nice way.

Reply to: