From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.5-pre1 (2020-06-20) on ip-172-31-74-118.ec2.internal X-Spam-Level: X-Spam-Status: No, score=-1.9 required=3.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.5-pre1 X-Received: by 2002:ac8:7405:: with SMTP id p5mr17569761qtq.231.1619450578582; Mon, 26 Apr 2021 08:22:58 -0700 (PDT) X-Received: by 2002:a25:4883:: with SMTP id v125mr26387564yba.253.1619450578423; Mon, 26 Apr 2021 08:22:58 -0700 (PDT) Path: eternal-september.org!reader02.eternal-september.org!news.uzoreto.com!newsfeed.xs4all.nl!newsfeed9.news.xs4all.nl!50.7.236.18.MISMATCH!news-out.netnews.com!news.alt.net!fdc3.netnews.com!peer01.ams1!peer.ams1.xlned.com!news.xlned.com!peer03.iad!feed-me.highwinds-media.com!news.highwinds-media.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail Newsgroups: comp.lang.ada Date: Mon, 26 Apr 2021 08:22:58 -0700 (PDT) Injection-Info: google-groups.googlegroups.com; posting-host=35.245.252.196; posting-account=XfA3zgkAAABoz6fRf3Tehtnqqr7Ycml- NNTP-Posting-Host: 35.245.252.196 User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: <649cc002-f0af-4824-ba68-e5c0cb2833b3n@googlegroups.com> Subject: but somewhat [different Ada95] _Private_ non-generic children of genevariant allowed. From: Vincent Marciante Injection-Date: Mon, 26 Apr 2021 15:22:58 +0000 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Received-Bytes: 2315 Xref: reader02.eternal-september.org comp.lang.ada:61906 List-Id: I pretty much follow the rational requiring children of generics that are= =20 meant to be used by users of a generic also be generic. But what about=20 the case that the child is only introduced for "separation of concerns" and= "information hiding" in the body of a generic package: Why can't _private_= children of a generic _always_ for use only in the implementation of the p= arent unit be allowed? That seems to me to be only a little more flexible= =20 version of the allowed arrangement where the desired functionality is expre= ssed in a body-local package that has _its_ implementation as separate stub= . So, I mean I have a situation where I like to be able to do the following b= ut can't. generic ... package Generic_Package is procedure Parent_Procedure; ... end; private package Generi _Package.Child is procedure GPC_Procedure; ... end; package body Generic_Package is ... procedure Parent_Procedure is separate; ... end; with Generic_Package.C hild; separate (Generic_Package) procedure Parent_Procedure is begin ... Generic_Package.Child.GPC_Procedure; ... end; =20