From: Robert A Duff <bobduff@shell01.TheWorld.com>
Subject: Re: advice on package design
Date: 21 Mar 2005 11:19:55 -0500
Date: 2005-03-21T11:19:55-05:00 [thread overview]
Message-ID: <wcc8y4heztg.fsf@shell01.TheWorld.com> (raw)
In-Reply-To: 423a9fc2$1_1@glkas0286.greenlnk.net
"Martin Dowie" <martin.dowie@baesystems.com> writes:
> Robert A Duff wrote:
> >> I've never understood why this needs to be this way...
> >
> > Because I2 is visible in the handler. But it's declaration is never
> > successfully elaborated, so it does not exist!
> >
> > procedure P is
> > X: Integer := F(...); -- raises Some_Error
> > Y: Integer := 123;
> > begin
> > ...
> > exception
> > when Some_Error =>
> > Put(X); Put(Y); -- What are the values of X and Y here?
> > end P;
>
> And we couldn't have come up with some form of words to get
> round that?!?!?!?! :-)
It's not a wording issue. It just doesn't make any sense to allow code
to refer to variables that do not exist.
What's needed is a syntax that better reflects the semantics.
It was a mistake in Ada 83 to attach handlers to scope-y things.
- Bob
next prev parent reply other threads:[~2005-03-21 16:19 UTC|newest]
Thread overview: 28+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-03-07 16:23 advice on package design spambox
2005-03-07 21:08 ` Dmitry A. Kazakov
2005-03-08 12:48 ` spambox
2005-03-08 17:18 ` Dmitry A. Kazakov
2005-03-12 19:57 ` Robert A Duff
2005-03-12 20:45 ` Dmitry A. Kazakov
2005-03-12 21:59 ` Robert A Duff
2005-03-13 9:23 ` Dmitry A. Kazakov
2005-03-16 20:41 ` Robert A Duff
2005-03-17 10:22 ` Dmitry A. Kazakov
2005-03-17 14:04 ` Robert A Duff
2005-03-17 15:59 ` Dmitry A. Kazakov
2005-03-17 19:10 ` Robert A Duff
2005-03-17 19:47 ` Martin Dowie
2005-03-17 20:55 ` Robert A Duff
2005-03-17 21:14 ` Marius Amado Alves
2005-03-18 9:31 ` Martin Dowie
2005-03-18 9:38 ` Martin Dowie
2005-03-21 16:19 ` Robert A Duff [this message]
2005-03-17 20:48 ` Dmitry A. Kazakov
2005-03-17 21:26 ` Robert A Duff
2005-03-18 3:06 ` Jared
2005-03-18 10:00 ` Dmitry A. Kazakov
2005-03-21 16:17 ` Robert A Duff
2005-03-21 18:16 ` Dmitry A. Kazakov
2005-03-21 20:35 ` Robert A Duff
2005-03-22 10:55 ` Dmitry A. Kazakov
2005-03-17 23:23 ` Randy Brukardt
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox