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=-0.3 required=5.0 tests=BAYES_00, REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,59e7405b37921f3e X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2003-06-21 00:09:27 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!headwall.stanford.edu!fu-berlin.de!uni-berlin.de!dialin-145-254-036-244.arcor-ip.NET!not-for-mail From: "Dmitry A. Kazakov" Newsgroups: comp.lang.ada Subject: Re: A good way to name instantiated children? Date: Sat, 21 Jun 2003 09:12:14 +0200 Organization: At home Message-ID: References: Reply-To: mailbox@dmitry-kazakov.de NNTP-Posting-Host: dialin-145-254-036-244.arcor-ip.net (145.254.36.244) Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7Bit X-Trace: fu-berlin.de 1056179365 25007493 145.254.36.244 (16 [77047]) User-Agent: KNode/0.7.1 Xref: archiver1.google.com comp.lang.ada:39517 Date: 2003-06-21T09:12:14+02:00 List-Id: Stephen Leake wrote: > I solve this by prefixing Gen_ to the generic package names: > > generic > type Number is private; > package Gen_A is ... > > generic > package Gen_A.Gen_B is ... > > Then the instantiations can be: > > with Gen_A; > package Float_A is new Gen_A (Float); > > with Gen_A.Gen_B; > package Float_A.B is new Float_A.Gen_B; > > Yes, the Gen_A.Gen_B.Gen_C.Gen_D is a little ugly. But the > instantiation names are nice, which is more important. And it makes it > clear from the package name whether the package is generic or not, > which is also helpful. Actually I am already calling the root generic packages Generic_Something. But I somehow missed the very fact that generic children are indeed generic! (:-)). It is a good idea, thank you! -- Regards, Dmitry A. Kazakov www.dmitry-kazakov.de