From: Vincent Marciante <INALID_EXCEPT_FOR_marciant@earthlink.net>
Subject: Re: "private with" proposal
Date: Wed, 04 Dec 2002 03:52:33 GMT
Date: 2002-12-04T03:52:33+00:00 [thread overview]
Message-ID: <3DED7C37.19D@earthlink.net> (raw)
In-Reply-To: uuq160jpbkkn0c@corp.supernews.com
Randy Brukardt wrote:
>
> Vincent Marciante wrote in message <3DEC42E0.407B@earthlink.net>...
> >Stephen Leake wrote:
> >
> >> You are correct, the "extra syntax" of "private" in the context
> clause
> >> is not strictly necessary; the compiler and reader could figure out
> >> what's going on.
> >>
> >> But what is the downside of having the extra syntax?
> >
> >Discussing in the same AI as the one pertaining to
> >visability _within_ hierarchies confuses to issue.
>
> The entire point is that visibility is the wrong model for this. The
> syntax is tied to a legality rule (not a visibility rule), in order that
> added or removing 'private' or moving a declaration from the private
> part to the visible part does not silently change the meaning of a
> program. (This is covered in the AI).
Okay, my phraseology reflected my inadaqate apreciation for
the distinction between visability rules and legality rules.
If the rule would be a legality rule, does that imply that
new syntax is strictly necessary?
> A secondary issue is the desire to think of the private part as a
> separate part. We discussed allowing separate compilation of private
> parts; in that case, 'private with' is just the context clause of the
> private part.
>
> The visibility rules are already way too complex in Ada, and your
> suggestion would make them even more complex. Moreover, changing a unit
> from private to non-private (or vice-versa) could silently change the
> meaning of a program from one legal meaning to a different legal
> meaning. (Currently, any such program is illegal, as the with would be
> illegal when the unit is private; with 'private with' as currently
> described, the use that causes the problem would be illegal.)
Okay, suggesting specifically a visibility rule was unintended.
> In any case, 'private with' is easy to describe, easy to understand,
> easy to use, and easy to implement. A better solution (such as separate
> compilation of private parts) may exist, but waiting for the perfect
> solution to an important problem when we have an adequate solution that
> we can use now would be a mistake.
> Randy Brukardt
Thanks for the condensed explanation.
--
Vinny
prev parent reply other threads:[~2002-12-04 3:52 UTC|newest]
Thread overview: 28+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-11-09 6:39 Style: always declare subrountines? Victor Porton
2002-11-09 11:09 ` sk
2002-11-09 12:34 ` Victor Porton
2002-11-09 14:34 ` Jim Rogers
2002-11-09 14:53 ` sk
2002-11-09 15:36 ` Robert A Duff
2002-11-09 16:16 ` Frank J. Lhota
2002-11-09 16:28 ` chris.danx
2002-11-09 18:36 ` Simon Wright
2002-11-12 17:31 ` Stephen Leake
2002-11-18 1:52 ` ;Re: " Richard Riehle
2002-11-28 10:32 ` John English
2002-11-28 12:52 ` Lutz Donnerhacke
2002-12-03 11:15 ` John English
2002-12-03 12:22 ` Lutz Donnerhacke
2002-12-03 13:11 ` John English
2002-12-03 14:31 ` Robert A Duff
2002-12-03 14:41 ` Lutz Donnerhacke
2002-11-28 17:49 ` Vincent Marciante
2002-12-03 11:09 ` John English
2002-11-28 18:45 ` "private with" proposal Vincent Marciante
2002-11-28 20:12 ` David C. Hoos, Sr.
2002-11-29 4:28 ` Vincent Marciante
2002-12-01 1:00 ` Dale Stanbrough
2002-12-02 18:20 ` Stephen Leake
2002-12-03 5:37 ` Vincent Marciante
2002-12-03 19:24 ` Randy Brukardt
2002-12-04 3:52 ` Vincent Marciante [this message]
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox