comp.lang.ada
 help / color / mirror / Atom feed
From: bobduff@world.std.com (Robert A Duff)
Subject: Re: idiom for task termination?
Date: 1997/02/18
Date: 1997-02-18T00:00:00+00:00	[thread overview]
Message-ID: <E5t6u8.Jzp@world.std.com> (raw)
In-Reply-To: 32FB6A6A.431E@elca-matrix.ch


In article <32FB6A6A.431E@elca-matrix.ch>,
Mats Weber  <Mats.Weber@elca-matrix.ch> wrote:
>Robert A Duff wrote:
>> 
>> In article <32FA10EF.32A@bix.com>, Tom Moran  <tmoran@bix.com> wrote:
>> >What's a good idiom for terminating tasks inside library packages?
>> >If I build a re-usable package which contains an internal task which
>> >has an 'entry quit' but does not have a select-terminate alternative,
>> 
>> Why not add a terminate alternative?  That's what it's for...
>
>Because tasks whose masters are library units other than the main
>program are not required to terminate, and the terminate alternative
>needs not be chosen.

This was not true in Ada 83, and is not true in Ada 95.  The RM83 was
not clear on this point, but AI-399 "clarifies" it.  And (I hope) RM95
is clear on this point.

In Ada 95, a task object declared immediately within a library package
depends directly on the environment task (not the package), and the
normal rules apply to terminate alternatives in this case (that is, if
all the tasks are waiting at terminate alts, then the env task and all
its dependents terminate).

- Bob




  reply	other threads:[~1997-02-18  0:00 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <32FA10EF.32A@bix.com>
1997-02-07  0:00 ` idiom for task termination? Robert A Duff
1997-02-07  0:00   ` Mats Weber
1997-02-18  0:00     ` Robert A Duff [this message]
1997-02-07  0:00   ` Tom Moran
1997-02-08  0:00 ` Matthew Heaney
1997-02-09  0:00   ` Tom Moran
1997-02-10  0:00     ` Matthew Heaney
1997-02-10  0:00   ` Mats Weber
1997-02-10  0:00     ` Matthew Heaney
1997-02-11  0:00       ` Tom Moran
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox