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.9 required=5.0 tests=BAYES_00,FORGED_GMAIL_RCVD, FREEMAIL_FROM autolearn=no autolearn_force=no version=3.4.4 X-Received: by 2002:a6b:cf04:: with SMTP id o4-v6mr1337305ioa.87.1528995493058; Thu, 14 Jun 2018 09:58:13 -0700 (PDT) X-Received: by 2002:aca:1214:: with SMTP id 20-v6mr195286ois.3.1528995492971; Thu, 14 Jun 2018 09:58:12 -0700 (PDT) Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!feeder.eternal-september.org!border1.nntp.ams1.giganews.com!nntp.giganews.com!feeds.phibee-telecom.net!newsfeed.xs4all.nl!newsfeed7.news.xs4all.nl!85.12.16.68.MISMATCH!peer01.ams1!peer.ams1.xlned.com!news.xlned.com!peer01.am4!peer.am4.highwinds-media.com!peer03.iad!feed-me.highwinds-media.com!news.highwinds-media.com!d7-v6no991374itj.0!news-out.google.com!c20-v6ni541itc.0!nntp.google.com!u78-v6no974999itb.0!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Newsgroups: comp.lang.ada Date: Thu, 14 Jun 2018 09:58:12 -0700 (PDT) In-Reply-To: Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=137.103.119.68; posting-account=ShYTIAoAAABytvcS76ZrG9GdaV-nXYKy NNTP-Posting-Host: 137.103.119.68 References: User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: <9f6c53bf-dda2-4cbd-bfd5-9eec03336418@googlegroups.com> Subject: Re: Unknown constraints and type composition From: sbelmont700@gmail.com Injection-Date: Thu, 14 Jun 2018 16:58:13 +0000 Content-Type: text/plain; charset="UTF-8" X-Received-Bytes: 1785 X-Received-Body-CRC: 1643598639 Xref: reader02.eternal-september.org comp.lang.ada:53103 Date: 2018-06-14T09:58:12-07:00 List-Id: One approach would be to use coextensions, assuming you are aware of all that entails, e.g.: type Inner (<>) is private; function Create_Inner return Inner; ... type Outer (<>) is private; function Create_Outer return Outer; private type Outer (x : access Inner) is null record; function Create_Outer return Outer is begin return Outer (x => new Inner'(Create_Inner)); end Create; And, assuming the compiler follows the advice (and is bug free :/ ) everything should work itself out safely and neatly. Though a portable way to do this would be nice. -sb