On Monday, Jan 30, 2023 Tucker Taft wrote:
>On Sat, Jan 28, 2023 at 1:15 AM Christoph & Ursula Grein
<[email protected]> wrote:

>>!topic Since implementations are allowed to round all ceiling priorities 
>>in subrange System.Priority[ to System.Priority'Last (see D.3)], an...
>>!reference Ada 2022 RM D.2.4(11/3) Draft 35
>>!from Grein 23-01-25
>>              
>>!discussion Something is wrong there - either lower limit is missing or 
>>upper limit is nonsense.
                
>Can you clarify what you believe is wrong? The sentence is saying that
>for any priority value in the (sub)range of System.Priority (which is
>equivalent to saying any value in the range System.Priority'First .. 
>System.Priority'Last), the implementation may treat it as though the 
>programmer specified the maximum allowed value, namely
System.Priority'Last.

Perhaps he is confused by the word "round"? This is not a conventional
rounding operation (where one sets a value to the nearest value that is
subject to some criteria). It's about setting all values in the range of
Priority to a single value. I would have not described that as "rounding",
it's more like "ignoring" the priority (since this makes all protected
objects compatible with all [non-interrupt] tasks).

OTOH, D.3 does use the word "round" to describe this operation, so the RM is
consistent. And I suppose in cases other than the one described in D.2.4, it
could actually act as rounding (when there are multiple ranges of priorities
that are rounded to multiple values).

I don't really see a way to make this better without rewriting D.3, and that
doesn't seem to be justified.

                       Randy.




________________________________________________________

You have received this message because you subscribed to the Ada-Comment
mailing list. To leave the Ada-Comment list, send an email with
'leave Ada-Comment' in the body to [email protected]. For help
on the other commands available, send 'help Ada-Comment' to the same address.
Problems? Send mail to [email protected]. This list is operated by the
Ada Resource Association, Inc., PO Box 8685, New York NY 10116-8685.




Reply via email to