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.7.204 with SMTP id f195mr2422906itf.37.1519418533968; Fri, 23 Feb 2018 12:42:13 -0800 (PST) X-Received: by 10.157.3.237 with SMTP id f100mr118829otf.6.1519418533761; Fri, 23 Feb 2018 12:42:13 -0800 (PST) Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!feeder.eternal-september.org!border1.nntp.ams1.giganews.com!nntp.giganews.com!peer01.ams1!peer.ams1.xlned.com!news.xlned.com!peer02.am4!peer.am4.highwinds-media.com!peer01.iad!feed-me.highwinds-media.com!news.highwinds-media.com!w142no916253ita.0!news-out.google.com!s63ni2599itb.0!nntp.google.com!w142no916248ita.0!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Newsgroups: comp.lang.ada Date: Fri, 23 Feb 2018 12:42:13 -0800 (PST) Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=85.240.211.93; posting-account=rhqvKAoAAABpikMmPHJSZh4400BboHwT NNTP-Posting-Host: 85.240.211.93 User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: <93229821-ae3d-4e47-91d9-a20ff3c1f1a7@googlegroups.com> Subject: two questions on allocators From: Mehdi Saada <00120260a@gmail.com> Injection-Date: Fri, 23 Feb 2018 20:42:13 +0000 Content-Type: text/plain; charset="UTF-8" X-Received-Body-CRC: 408999543 X-Received-Bytes: 2118 Xref: reader02.eternal-september.org comp.lang.ada:50611 Date: 2018-02-23T12:42:13-08:00 List-Id: 2.2/3: for an allocator with a subtype indication, the subtype indication shall not specify a null exclusion why type A is access INTEGER; type B is access not null A; type C is access B; Object_C : C := new B; is allowed, but not type A is access INTEGER; type B is access A; type C is access B; Object_C : C := new not null B; ?? What's the difference ? _______________________________ If the designated type of the allocator is class-wide, the accessibility level of the type determined by the subtype_indication or qualified_expression shall not be statically deeper than that of the type of the allocator. -> what means the last "type of the allocator" ? Is it the same than "designed type of the allocator" ? Does it refer to this situation ? -> type T is access some_tagged_type'Class; POINTER : T; declare type CHILD is new some_tagged_type with ... begin POINTER := new CHILD; --illegal end; Technical details of this section aren't gonna matter for me any time soon, so that will be all.