comp.lang.ada
 help / color / mirror / Atom feed
From: Tucker Taft <stt@averstar.com>
Subject: Re: Help Me Please :)
Date: 2000/03/20
Date: 2000-03-20T20:20:38+00:00	[thread overview]
Message-ID: <38D68815.6A181FAA@averstar.com> (raw)
In-Reply-To: Pine.BSF.4.21.0003200940510.6400-100000@shell5.ba.best.com

Brian Rogoff wrote:
> ...
> I think exception types would be a good thing, but its way too late to fix
> that now, and it was probably too late for Ada 95.

In fact, early in the Ada 9X process we proposed the equivalent of
parameterized exceptions that formed a hierarchy.  All quite elegant.
It could still be done in my view.  It was just beyond what the 
reviewers were ready for at the time.

An alternative simpler addition is to add a package "Ada.Exceptions.Objects"
or equivalent, which allows one to "Raise_With_Object" where you could
pass in an object of any type extended from, say, Exception_Object_Root,
and be able to retrieve it given an Exception_Occurrence, in the same
way one can pass in a string, and retrieve it.  We might set some
arbitrary upper limit on the 'Size of the object passed in that must
be supported by an implementation, e.g. 1500 bits (analogous to the
200 character limit for exception messages).

> ... A future Ada-inspired
> language could fix this.

It's really not that far fetched.  E.g.:

    Out_Of_Space : Exception(X : Integer; Y : access Blob) is 
      new Storage_Error;
    ...
    raise Out_Of_Space(X => 5, Y => Blurfo'Access);
    ...
  when OOS : Out_Of_Space => 
      Put_Line("Out of space, needed: " & Integer'Image(OOS.X));

> -- Brian

-Tuck

-- 
-Tucker Taft   stt@averstar.com   http://www.averstar.com/~stt/
Technical Director, Distributed IT Solutions  (www.averstar.com/tools)
AverStar (formerly Intermetrics, Inc.)   Burlington, MA  USA




  reply	other threads:[~2000-03-20  0:00 UTC|newest]

Thread overview: 54+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2000-02-29  0:00 Help Me Please :) Will Mann
2000-03-01  0:00 ` Robert Dewar
2000-03-03  0:00   ` Florian Weimer
2000-03-03  0:00     ` tmoran
2000-03-04  0:00       ` Richard D Riehle
2000-03-05  0:00         ` Steve Arnold
2000-03-17  0:00         ` Robert A Duff
2000-03-18  0:00           ` Richard D Riehle
2000-03-18  0:00           ` James S. Rogers
2000-03-19  0:00             ` Robert A Duff
2000-03-20  0:00               ` Brian Rogoff
2000-03-20  0:00                 ` Tucker Taft [this message]
2000-03-20  0:00           ` Florian Weimer
2000-03-22  0:00           ` Mats Weber
2000-03-27  0:00             ` Robert A Duff
2000-03-27  0:00               ` Hyman Rosen
2000-03-28  0:00               ` Robert Dewar
2000-03-30  0:00                 ` Mats Weber
2000-04-06  0:00                   ` Exceptions (was: " Wes Groleau
2000-04-07  0:00                     ` Mats Weber
2000-03-28  0:00               ` reason67
2000-03-28  0:00                 ` Robert Dewar
2000-03-29  0:00                   ` reason67
2000-03-29  0:00                   ` Simon Wright
2000-04-06  0:00                   ` Simon Pilgrim
2000-04-07  0:00                     ` Robert Dewar
2000-04-10  0:00                       ` r_c_chapman
2000-03-29  0:00               ` Richard D Riehle
2000-03-29  0:00                 ` Robert Dewar
2000-03-31  0:00                   ` Richard D Riehle
2000-03-31  0:00                     ` Jean-Pierre Rosen
2000-03-31  0:00                       ` Pascal Obry
2000-03-30  0:00                 ` Mats Weber
2000-03-31  0:00                   ` Richard D Riehle
2000-04-06  0:00                 ` Wes Groleau
2000-03-30  0:00               ` Tucker Taft
2000-03-30  0:00               ` Mats Weber
     [not found]     ` <2000Mar3.183321.69279@ludens>
2000-03-03  0:00       ` Larry Kilgallen
2000-03-04  0:00       ` Robert Dewar
     [not found] <df481109.0106140310.5d923746@posting.google.com>
     [not found] ` <9gb1uu$87u7o$1@ID-52877.news.dfncis.de>
2001-06-19  2:59   ` help me please! Ken Garlington
2001-06-16 10:20     ` C.D.Damron
2001-06-20  6:06     ` John Keeney
  -- strict thread matches above, loose matches on Subject: below --
2000-02-29  0:00 Help Me Please :) Will Mann
2000-02-29  0:00 ` Stanley R. Allen
2000-02-29  0:00   ` Al Johnston
2000-03-01  0:00     ` Robert Dewar
2000-03-01  0:00     ` Robert Dewar
2000-03-01  0:00       ` Al Johnston
2000-03-01  0:00     ` Stanley R. Allen
2000-03-01  0:00     ` tmoran
2000-03-01  0:00       ` Al Johnston
2000-03-02  0:00       ` Aidan Skinner
2000-03-01  0:00 ` James Bean
2000-03-01  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