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=ham autolearn_force=no version=3.4.4 X-Google-Thread: a07f3367d7,344faf475a6f812a X-Google-Attributes: gida07f3367d7,public,usenet X-Google-NewGroupId: yes X-Google-Language: ENGLISH,ASCII-7-bit X-Received: by 10.224.185.17 with SMTP id cm17mr9048898qab.6.1366739877139; Tue, 23 Apr 2013 10:57:57 -0700 (PDT) X-Received: by 10.182.104.228 with SMTP id gh4mr381625obb.27.1366739877086; Tue, 23 Apr 2013 10:57:57 -0700 (PDT) Path: ef9ni12521qab.0!nntp.google.com!gp5no5316042qab.0!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Newsgroups: comp.lang.ada Date: Tue, 23 Apr 2013 10:57:56 -0700 (PDT) In-Reply-To: Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=66.126.103.122; posting-account=duW0ogkAAABjRdnxgLGXDfna0Gc6XqmQ NNTP-Posting-Host: 66.126.103.122 References: <97967083-d21d-4de2-aeb8-76d0d5818993@googlegroups.com> User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: <03e84773-d616-4a46-8189-93ae4ab5fcbf@googlegroups.com> Subject: Re: Interresting difference in Normal-Returns/Expression-Functions and Extended-Returns. From: Adam Beneschan Injection-Date: Tue, 23 Apr 2013 17:57:57 +0000 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Date: 2013-04-23T10:57:56-07:00 List-Id: On Tuesday, April 23, 2013 9:52:04 AM UTC-7, Simon Wright wrote: >=20 > > The upshot of all this is that, by 7.6.1(4) and 9.3(2), in Make_ER, > > the task created by the allocator *depends* *on* the body of Make_ER, > > and therefore the body of Make_ER cannot complete until the task has > > completed. That should be enough to explain the results. >=20 > Yes, but there are other similar side effects: in the tests, OP wrote >=20 > declare > function Make(Input : in String) return not null access Testing > renames Make_EF; >=20 > P : constant array (Positive range <>) of > not null access constant Testing:=3D > ( Make("Bob"), Make("Steve"), Make("Dave"), Make("Joey") ); > begin > null; > end TEST_1; >=20 > and the code doesn't exit the declare block until all the tasks have > completed. I don't see a language reason for that. The tasks are all created with all= ocators, and the type of the allocator alone should determine what master t= he tasks depend on--not a block declaring an array that contains the access= objects. If it's true that the block doesn't exit until all the tasks cre= ated by allocators have completed, then it's probably a GNAT bug. I'd need= to study it more carefully to make sure, though. There may be some releva= nt language rules I'm missing, or something else I'm missing. -- Adam