comp.lang.ada
 help / color / mirror / Atom feed
From: "J-P. Rosen" <rosen@adalog.fr>
Subject: Re: Example question
Date: Sun, 26 Oct 2014 16:46:55 +0100
Date: 2014-10-26T16:46:55+01:00	[thread overview]
Message-ID: <m2j529$o1b$1@dont-email.me> (raw)
In-Reply-To: <544d02cc$0$14840$c00b7f07@94.232.116.90>

Le 26/10/2014 15:18, Martyn Pike a écrit :
>> Tutorial says "If calls to both entries are already pending, one will
>> be accepted non-deterministically." what does that mean? If calls are
>> pending on bith entries it might happend that Shutdown is accepted and
>> exits in which case thats not good solution at all
>>
>>
> 
> It basically means exactly what you said.  If calls are pending on both
> entries then it is not deterministic as to which one will be processed
> first. 
No. "one of them is selected according to the entry queuing policy in
effect" (9.7.1(16))

It was never non deterministic. Implementation defined in previous
versions of the language.

> If you want deterministic behaviour then in my opinion this is where
> protected objects should be used.  Particularly if you absolutely must
> check for the existence of a Shutdown event before checking for a
> Recalculate event.
If you tell what kind of deterministic behaviour you want, it is easy to
write the expected behaviour with rendezvous.

-- 
J-P. Rosen
Adalog
2 rue du Docteur Lombard, 92441 Issy-les-Moulineaux CEDEX
Tel: +33 1 45 29 21 52, Fax: +33 1 45 29 25 00
http://www.adalog.fr

  reply	other threads:[~2014-10-26 15:46 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-10-26 13:27 Example question compguy45
2014-10-26 14:18 ` Martyn Pike
2014-10-26 15:46   ` J-P. Rosen [this message]
2014-10-26 16:53     ` Martyn Pike
2014-10-26 14:21 ` Shark8
2014-10-26 15:42   ` Simon Wright
2014-10-26 15:48   ` Robert A Duff
2014-10-26 14:33 ` Niklas Holsti
replies disabled

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