From: Laurent.Guerby@enst-bretagne.fr (Laurent Guerby)
Subject: Re: Common Error/Exception Handler
Date: 1996/04/22
Date: 1996-04-22T00:00:00+00:00 [thread overview]
Message-ID: <4xzq84ypq6.fsf@leibniz.enst-bretagne.fr> (raw)
In-Reply-To: Dq4p9v.Jv3@world.std.com
John Cupak:
: Wouldn't it be possible with the Ada 95 exception mechanisms to create a
: package of standard exceptions and a common error message procedure,
: import/rename the exceptions where appropriate, and let the common error
: message procedure take care of the details?
Robert A Duff wrote:
: I suppose it's possible, but it doesn't seem desirable. The abstraction
: in question ought to define what sort of things are errors, and what
: exceptions are therefore raised. Clients can then decide how to handle
: those errors. Why do you think this information ought to be more
: global?
John Cupak wrote:
:I was thinking that a "global error/exception handler" package would be easier
: to maintain, since *all* error definitions and messages would be in a single
: place.
:
: Comments?
I don't think you (John) are talking about exceptions in general
(like Bob), but about exceptions that get propagated to the main unit
and are "user" reported as a console message or in a log file.
In this last case, a global mechanism is desirable and simple to
implement in Ada 95 as a global error reporting package using new Ada
(95) features in this area.
You should have a look at RM95-A.13, and see that in Ada 95, all IO
exceptions are defined in a single package, Ada.IO_Exceptions, and
renamed when needed elsewhere ;-). In Ada 95 a message can be
associated to an exception occurence, see RM95-11.4.1, Ada.Exceptions.
--
-- Laurent Guerby, student at Telecom Bretagne (France), Team Ada.
-- "Use the Source, Luke. The Source will be with you, always (GPL)."
-- http://www-eleves.enst-bretagne.fr/~guerby/ (GATO Project).
-- Try GNAT, the GNU Ada 95 compiler (ftp://cs.nyu.edu/pub/gnat).
next prev parent reply other threads:[~1996-04-22 0:00 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
1996-04-19 0:00 Common Error/Exception Handler John Cupak
1996-04-19 0:00 ` Robert A Duff
1996-04-22 0:00 ` Laurent Guerby [this message]
1996-04-22 0:00 ` John Cupak
1996-04-23 0:00 ` Michel Gauthier
1996-04-24 0:00 ` Michel Gauthier
1996-05-04 0:00 ` LJMetzger
1996-05-04 0:00 ` Theodore E. Dennison
1996-05-08 0:00 ` John English
1996-05-10 0:00 ` Theodore E. Dennison
1996-05-09 0:00 ` Jon S Anthony
1996-05-10 0:00 ` John English
1996-05-10 0:00 ` Robert A Duff
-- strict thread matches above, loose matches on Subject: below --
1996-04-24 0:00 tmoran
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox