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,FREEMAIL_FROM autolearn=unavailable autolearn_force=no version=3.4.4 X-Received: by 10.236.43.229 with SMTP id l65mr4492054yhb.30.1382973821704; Mon, 28 Oct 2013 08:23:41 -0700 (PDT) X-Received: by 10.50.67.17 with SMTP id j17mr180521igt.8.1382973821263; Mon, 28 Oct 2013 08:23:41 -0700 (PDT) Path: border1.nntp.dca3.giganews.com!backlog3.nntp.dca3.giganews.com!border3.nntp.dca.giganews.com!border1.nntp.dca.giganews.com!nntp.giganews.com!o2no6052331qas.0!news-out.google.com!rn2ni128316pbc.1!nntp.google.com!o2no6052311qas.0!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Newsgroups: comp.lang.ada Date: Mon, 28 Oct 2013 08:23:40 -0700 (PDT) In-Reply-To: Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=137.121.198.151; posting-account=cumtSQoAAABneUE0cNB48vDg9pu8LzVu NNTP-Posting-Host: 137.121.198.151 References: <4395468b-93d3-45f4-8bc0-91cd646ff1d9@googlegroups.com> User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: Subject: Re: Warning: accessibility check failure with GNAT GPL 2013 From: sangomarco@gmail.com Injection-Date: Mon, 28 Oct 2013 15:23:41 +0000 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Original-Bytes: 2237 Xref: number.nntp.dca.giganews.com comp.lang.ada:183747 Date: 2013-10-28T08:23:40-07:00 List-Id: Le lundi 28 octobre 2013 15:26:33 UTC+1, Dmitry A. Kazakov a =E9crit=A0: > On Mon, 28 Oct 2013 06:49:30 -0700 (PDT), sangomarco@gmail.com wrote: >=20 >=20 >=20 > > function New_Thread return access Cyclic_Thread is >=20 > > begin >=20 > > return new Cyclic_Thread; >=20 > > end New_Thread; >=20 >=20 >=20 > The rule of thumb: you never return an anonymous access result allocated = by >=20 > new. > Thanks for your quick response. I don't have enough experience with Ada, pl= ease could you tell me more about the rule? I don't understand why this is = not allow. My goal is to create a main task which makes a successor tasks i= f necessarry. And, since I cannot use the sybtype mak to create a new task = in the current execution of a main task body as the following declaration Next : access Cyclic_Thread; next : new Cyclick_Thread; I lazily use the previous function to return the access to the task. -- Best regards Marc