From: Dmitry A.Kazakov <mailbox@dmitry-kazakov.de>
Subject: Re: Overriding discriminants perplexes GNAT 3.14p
Date: Sat, 21 Sep 2002 00:06:27 +0200
Date: 2002-09-21T00:06:27+02:00 [thread overview]
Message-ID: <amerh4$5b11r$2@ID-77047.news.dfncis.de> (raw)
In-Reply-To: b4682ab7.0209191022.43137826@posting.google.com
Adam Beneschan wrote:
> Dmitry A.Kazakov <mailbox@dmitry-kazakov.de> wrote in message
> news:<amc58u$4ebgo$1@ID-77047.news.dfncis.de>...
>
>> 2. Circular requeue hangs at run-time under Linux:
>>
>> package Objects is
>> protected Object1 is
>> entry Point1;
>> entry Point2;
>> end Object1;
>> protected Object2 is
>> entry Point1;
>> end Object2;
>> end Objects;
>> ------------
>> package body Objects is
>> protected body Object1 is
>> entry Point1 when True is
>> begin
>> requeue Object2.Point1;
>> end Point1;
>> entry Point2 when True is
>> begin
>> null;
>> end Point2;
>> end Object1;
>> protected body Object2 is
>> entry Point1 when True is
>> begin
>> requeue Object1.Point2;
>> end Point1;
>> end Object2;
>> end Objects;
>> ------------
>> with Ada.Text_IO; use Ada.Text_IO;
>> with Objects;
>>
>> procedure Test is
>> begin
>> Objects.Object1.Point1;
>> Put_Line ("That's OK");
>> end Test;
>
> I think GNAT's behavior is legitimate here. Protected entry calls and
> external requeues start new "protected actions" on the target
> protected object (9.5.3(8), 9.5.4(11)). Thus, when
> Objects.Object1.Point1 is called, a new protected action is started on
> Object1. When this requeues to Object2.Point1, a new protected action
> is started on Object2; however, the protected action on Object1 does
> not complete (AI95-00148).
Really? 9.5.4(10) says explicitly (for an internal requeue) that the
ongoing action continues., but following it 9.5.4(11) keeps silence about
that. From which I would assume that the ongoing action is replaced by a
new one. If not, then a task may simultaneously perform an unlimited number
of protected actions! I see no sense in that, and moreover, it would make
external requeues almost useless.
--
Regards,
Dmitry Kazakov
www.dmitry-kazakov.de
next prev parent reply other threads:[~2002-09-20 22:06 UTC|newest]
Thread overview: 31+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-09-19 2:32 Overriding discriminants perplexes GNAT 3.14p Dmitry A.Kazakov
2002-09-18 16:45 ` Stephen Leake
2002-09-19 21:34 ` Dmitry A.Kazakov
2002-09-19 15:51 ` Stephen Leake
2002-09-20 22:06 ` Dmitry A.Kazakov
2002-09-20 12:29 ` Stephen Leake
2002-09-22 8:43 ` Dmitry A.Kazakov
2002-09-22 13:32 ` Georg Bauhaus
2002-09-23 5:41 ` Dmitry A.Kazakov
2002-09-23 12:41 ` Georg Bauhaus
2002-09-24 1:38 ` Dmitry A.Kazakov
2002-09-23 15:33 ` Stephen Leake
2002-09-24 8:35 ` Dmitry A. Kazakov
2002-09-19 18:22 ` Adam Beneschan
2002-09-20 22:06 ` Dmitry A.Kazakov [this message]
2002-09-20 16:00 ` Adam Beneschan
2002-09-22 8:43 ` Dmitry A.Kazakov
2002-09-23 21:18 ` Adam Beneschan
2002-09-24 9:40 ` Dmitry A. Kazakov
2002-09-21 13:01 ` Simon Wright
2002-09-18 16:46 ` Mark Johnson
2002-09-19 21:34 ` Dmitry A.Kazakov
2002-09-19 16:17 ` Stephen Leake
2002-09-19 20:02 ` tmoran
2002-09-20 21:10 ` Dmitry A.Kazakov
2002-09-21 12:56 ` Simon Wright
2002-09-18 16:49 ` Frank J. Lhota
2002-09-19 21:34 ` Dmitry A.Kazakov
2002-09-18 17:17 ` Per Sandbergs
2002-09-19 8:51 ` Thierry Lelegard
-- strict thread matches above, loose matches on Subject: below --
2002-09-19 9:08 Grein, Christoph
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox