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.2 required=5.0 tests=BAYES_00,FREEMAIL_FROM, FROM_STARTS_WITH_NUMS autolearn=no autolearn_force=no version=3.4.4 X-Received: by 10.36.19.2 with SMTP id 2mr1861455itz.4.1516716333911; Tue, 23 Jan 2018 06:05:33 -0800 (PST) X-Received: by 10.157.1.22 with SMTP id 22mr510434otu.0.1516716333766; Tue, 23 Jan 2018 06:05:33 -0800 (PST) Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!feeder.eternal-september.org!news.unit0.net!peer03.am4!peer.am4.highwinds-media.com!peer01.iad!feed-me.highwinds-media.com!news.highwinds-media.com!border1.nntp.dca1.giganews.com!nntp.giganews.com!g80no2386104itg.0!news-out.google.com!s63ni3375itb.0!nntp.google.com!g80no2386103itg.0!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Newsgroups: comp.lang.ada Date: Tue, 23 Jan 2018 06:05:33 -0800 (PST) In-Reply-To: Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=85.243.127.244; posting-account=rhqvKAoAAABpikMmPHJSZh4400BboHwT NNTP-Posting-Host: 85.243.127.244 References: <193126c2-f171-43ed-8c7c-00570f1dd4d4@googlegroups.com> User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: Subject: Re: making a son benefit access ton an instanciation of a generic package required as a formal parameter to his father and instanciated by him From: Mehdi Saada <00120260a@gmail.com> Injection-Date: Tue, 23 Jan 2018 14:05:33 +0000 Content-Type: text/plain; charset="UTF-8" X-Received-Bytes: 2212 X-Received-Body-CRC: 954541025 Xref: reader02.eternal-september.org comp.lang.ada:50071 Date: 2018-01-23T06:05:33-08:00 List-Id: I really have a hard time with technical terms. To sum up my understanding (excluding use of limited_with), a picture is worth a thousand words. Is that ok ? with Generic_package_P0; with normal_package; private with private_only; generic with package P1 is new P1_G; package P2_G is package P0 is new Generic_package_P0;[...]; private package P0_v2 is new Generic_package_P0; -- private_only visible end P2_G; generic package P2_G.Child is -- Generic_package_P0, normal_package, P0 visible -- can also instanciate Generic_package_P0, whose instance will be visible below in private and body part. private -- the same, P0_V2 is also visible P0_v2 and private_only end P2_G.Child; package body P2_G.Child -- same for instanciating any generic. -- exact same than above in private part, plus things declared here and hidden from above as well as for later children. end body P2_G.Child;