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!feeder.eternal-september.org!aioe.org!.POSTED.6k1R0IQgF+3y+m4EkNohlQ.user.gioia.aioe.org!not-for-mail From: Simon Wright Newsgroups: comp.lang.ada Subject: Re: How can one record component be local and another not? Date: Thu, 07 May 2020 14:25:19 +0100 Organization: Aioe.org NNTP Server Message-ID: References: NNTP-Posting-Host: 6k1R0IQgF+3y+m4EkNohlQ.user.gioia.aioe.org Mime-Version: 1.0 Content-Type: text/plain X-Complaints-To: abuse@aioe.org User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.3 (darwin) X-Notice: Filtered by postfilter v. 0.9.2 Cancel-Lock: sha1:3EesDobx85kexTQyPbx2S8eWCzM= Xref: reader01.eternal-september.org comp.lang.ada:58627 Date: 2020-05-07T14:25:19+01:00 List-Id: Niklas Holsti writes: >> No, tasks declared in library packages could survive the main program. > > And the environment task, yes. I've seen people suggest aborting the environment task as a way of ending a program with library tasks .. I suppose the main program could exit without terminating the environment task .. looking at ARM 10.2, (25) says "When the environment task completes (normally or abnormally), it waits for the termination of all such tasks, and then finalizes any remaining objects of the partition." but (30) says "If the environment task completes abnormally, the implementation may abort any dependent tasks.". Cortex GNAT RTS treats exiting the main program as the same as exiting any other taks body, i.e. illegal under Ravenscar, but I suppose I could include 'delay until Ada.Real_Time.Time_Last;' - might result in fewer surprises and would be more ARM-compliant.