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: 103376,22ab316b1096e177 X-Google-NewGroupId: yes X-Google-Attributes: gida07f3367d7,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news2.google.com!news3.google.com!feeder1-2.proxad.net!proxad.net!feeder2-2.proxad.net!newsfeed.arcor.de!newsspool4.arcor-online.net!news.arcor.de.POSTED!not-for-mail Date: Mon, 01 Nov 2010 21:08:37 +0100 From: Georg Bauhaus User-Agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.6; en-US; rv:1.9.2.12) Gecko/20101027 Thunderbird/3.1.6 MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: Re: Tasks, Entries, and Variables of a Class-wide type References: <7e77bb8f-17b6-4d51-9946-ea825f726682@f33g2000yqh.googlegroups.com> <3dcee4c7-9753-41a1-8181-6e7e363bfbe8@t13g2000yqm.googlegroups.com> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Message-ID: <4ccf1e46$0$6972$9b4e6d93@newsspool4.arcor-online.net> Organization: Arcor NNTP-Posting-Date: 01 Nov 2010 21:08:38 CET NNTP-Posting-Host: 14747076.newsspool4.arcor-online.net X-Trace: DXC=GXA<^LbZTH\\PS5Xo=M[RV4IUKjfR X-Complaints-To: usenet-abuse@arcor.de Xref: g2news2.google.com comp.lang.ada:16096 Date: 2010-11-01T21:08:38+01:00 List-Id: On 11/1/10 8:23 PM, Dmitry A. Kazakov wrote: > On Mon, 01 Nov 2010 11:50:44 -0700, Jeffrey Carter wrote: > >> On 11/01/2010 08:30 AM, Shark8 wrote: >>> >>> Crap; you're right! >>> While I certainly like the idea of having a task-construct within the >>> language itself, I'm still quite new to using them in-practice. >>> Thanks for pointing that out. >> >> Interestingly, your original problem does not exist if you use composition >> rather than type extension. > > No, the original problem is that an object of unconstrained type cannot be > returned from an entry point. That is independent on whether the constraint > is the type tag, discriminant without a default, or array bounds. > One may, however, pass data indirectly, and return a pointer or other designating value. (Or have the task trigger the actions to be performed on the new object without passing it around; instead, pass the actions.)