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-Thread: 103376,2948948ddf794344 X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news2.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!newsfeed00.sul.t-online.de!t-online.de!newsfeed.freenet.de!news.albasani.net!nuzba.szn.dk!news.jacob-sparre.dk!pnx.dk!not-for-mail From: "Randy Brukardt" Newsgroups: comp.lang.ada Subject: Re: Stupid question Date: Fri, 13 Apr 2007 18:39:52 -0500 Organization: Jacob's private Usenet server Message-ID: References: <1176414032.163717.31900@y80g2000hsf.googlegroups.com> <1176415338.362267.115580@l77g2000hsb.googlegroups.com> <1pyl2asiynhjs.117mopb54gcj7$.dlg@40tude.net> <1176478553.026938.254630@n59g2000hsh.googlegroups.com> <190oqb9t3eplx$.ffakhbeqreff$.dlg@40tude.net> NNTP-Posting-Host: static-69-95-181-76.mad.choiceone.net X-Trace: jacob-sparre.dk 1176507500 23843 69.95.181.76 (13 Apr 2007 23:38:20 GMT) X-Complaints-To: news@jacob-sparre.dk NNTP-Posting-Date: Fri, 13 Apr 2007 23:38:20 +0000 (UTC) X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2800.1807 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1807 Xref: g2news1.google.com comp.lang.ada:15003 Date: 2007-04-13T18:39:52-05:00 List-Id: "Markus E Leypold" wrote in message news:y7zm5chxxf.fsf@hod.lan.m-e-leypold.de... > > "Randy Brukardt" writes: > > > "Dmitry A. Kazakov" wrote in message > > news:190oqb9t3eplx$.ffakhbeqreff$.dlg@40tude.net... > >> On 13 Apr 2007 08:35:53 -0700, Adam Beneschan wrote: > > ... > >> This does not outlaw A.B, it just cannot. A trivial counter example is: > >> > >> with A.B; -- This is 100% legal > >> > >> With clause is defined in 10.1.2(4) as "with ". Here is the > >> same as in 12.7. It refers to 4.1 and is resolved to . > >> > >> Any language lawyers here? > > > > Sorry, Adam is right. A generic package is not a package (that's a standing > > ARG joke, not one of the RM's finest hours of terminology). Context clauses > > have their own, unique visibility rules defined in 10.1.6; you can't use > > them as a counterexample for anything. There is a very complex rule that > > allows you to say A.B there, because it normally would not be. > > Interestingly, the Ada 95 standard did not allow naming a grandchild that > > way (that is, A.B.C), which demonstrates how complex it is. > > So it is possible to say 'with A.B' in the context of a compilation > unit if A is "only" a generic (as opposed to an instance)? Even in Ada > 95? Is there any example for that somewhere? It's necessary to make children of generic packages work. Recall that a child of a generic must be a generic. The original question included an example. (Personally, I think generic children aren't worth the trouble, both in the language definition and in implementation. YMMV.) Randy.