From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,4d972ac0c79198a5 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2003-05-16 18:04:08 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!newsfeed!nntp.TheWorld.com!not-for-mail From: Robert A Duff Newsgroups: comp.lang.ada Subject: Re: Generic child units Date: 16 May 2003 21:04:07 -0400 Organization: The World Public Access UNIX, Brookline, MA Message-ID: References: <3ec12f93$1@epflnews.epfl.ch> <3ec1f6ab$1@epflnews.epfl.ch> NNTP-Posting-Host: shell01.theworld.com Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: pcls4.std.com 1053133447 21305 199.172.62.241 (17 May 2003 01:04:07 GMT) X-Complaints-To: abuse@TheWorld.com NNTP-Posting-Date: Sat, 17 May 2003 01:04:07 +0000 (UTC) User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.2 Xref: archiver1.google.com comp.lang.ada:37424 Date: 2003-05-16T21:04:07-04:00 List-Id: Stephen Leake writes: > Robert A Duff writes: > > Here's the AARM text: > > > > 18 A child of a parent generic package shall be instantiated or renamed > > only within the declarative region of the parent generic. > > But in my code above, Chi is an instantiation of "a child of a parent > generic package", and it is _not_ "within the declarative region of > the parent generic". No, Chi is not a child of Parent, it is a child of Par, which is a package, not a generic package. > I see. So I actually instantiated Par.Child (as the code actually says > :), which is _not_ a "child of a generic parent", even though I think > of it that way. That's right. It's very similar to what happens if you had Child physically nested within Parent. The way to think of it is, when you instantiate Parent as Par, you get a copy of all the children, and they are called (for example) Par.Child. However you can't *see* them unless you say "with Parent.Child". The "with Parent.Child" has a somewhat magical effect: it makes *.Child visible, for all * that are instances of Parent (Par, in your case). > That makes sense. As is sometimes the case, the ARM is not immediately > clear to us non-lawyers. Well, this is one of the more arcane rules in the language. - Bob