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.9 required=5.0 tests=BAYES_00 autolearn=unavailable autolearn_force=no version=3.4.4 Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!news.eternal-september.org!news.eternal-september.org!news.eternal-september.org!feeder.eternal-september.org!feeder.erje.net!eu.feeder.erje.net!news.albasani.net!news.teledata-fn.de!newsfeed.arcor.de!newsspool2.arcor-online.net!news.arcor.de.POSTED!not-for-mail Date: Mon, 28 Oct 2013 17:13:41 +0100 From: Georg Bauhaus User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.7; rv:17.0) Gecko/20130801 Thunderbird/17.0.8 MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: Re: Warning: accessibility check failure with GNAT GPL 2013 References: <4395468b-93d3-45f4-8bc0-91cd646ff1d9@googlegroups.com> In-Reply-To: X-Enigmail-Version: 1.5.1 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Message-ID: <526e8d35$0$9522$9b4e6d93@newsspool1.arcor-online.net> Organization: Arcor NNTP-Posting-Date: 28 Oct 2013 17:13:41 CET NNTP-Posting-Host: d89e0679.newsspool1.arcor-online.net X-Trace: DXC=iamNjUn::TE^B]`=U:WelBic==]BZ:afN4Fo<]lROoRAnkgeX?EC@@@_VX:i1JEGkJnc\616M64>JLh>_cHTX3jM]Tbf_1iS>RC X-Complaints-To: usenet-abuse@arcor.de Xref: news.eternal-september.org comp.lang.ada:17552 Date: 2013-10-28T17:13:41+01:00 List-Id: On 28.10.13 16:49, Dmitry A. Kazakov wrote: > Use a named access type instead. E.g. > > type Cyclic_Thread_Ptr is access all Cyclic_Thread: 2nd. And consider dropping "all" from the above type declaration, if possible. In your example, all pointers point to tasks of type Cyclic_Thread that were created by an allocator, so "all" is not needed. (Because you do not store the 'Access of some "non-heap" task object in some pointer variable.) (In general, it is best to avoid anonymous types, as they are a source of trouble, as they hide information, leaving the compiler in the dark about the scope of the anonymous type, and as they may also require additional run-time checks, like Dmitry explains.)