comp.lang.ada
 help / color / mirror / Atom feed
From: "Randy Brukardt" <randy@rrsoftware.com>
Subject: Re: Shouldn't there be a paragraph like 7.3.2(5/3) in 3.2.4?
Date: Mon, 12 May 2014 17:26:28 -0500
Date: 2014-05-12T17:26:28-05:00	[thread overview]
Message-ID: <lkrhqk$een$1@loke.gir.dk> (raw)
In-Reply-To: dd27f835-8295-4cb2-aa28-2ff3f351b0e0@googlegroups.com

"Adam Beneschan" <adambeneschan@gmail.com> wrote in message 
news:dd27f835-8295-4cb2-aa28-2ff3f351b0e0@googlegroups.com...
>On Monday, May 12, 2014 5:54:52 AM UTC-7, Jacob Sparre Andersen wrote:
>> Reading the fine print on subtype predicates and type invariants, I
>> noticed that section 3.2.4 (on subtype predicates) doesn't have a
>> paragraph matching 7.3.2(5/3) (on type invariants).
>>
>> 7.3.2(5/3): Within an invariant expression, the identifier of the first
>>             subtype of the associated type denotes the current instance
>>             of the type. Within an invariant expression associated with
>>             type T, the type of the current instance is T for the
>>             Type_Invariant aspect and T'Class for the
>>             Type_Invariant'Class aspect.
>
>FYI, the first sentence is true for both subtype predicates and type 
>invariants.  It's actually redundant in 7.3.2(5/3), >and the AARM shows it 
>as such (http://www.ada-auth.org/standards/12aarm/html/AA-7-3-2.html); 
>13.1.1(12/3) >applies to all aspect clauses on type and subtype 
>declarations.  I'd guess that the authors felt that in 7.3.2(5/3), they 
> >needed to repeat the rule in the first sentence in order to provide some 
>context to help readers understand the >second sentence.

Right; this is the consequence of other rules and does not need to be 
mentioned in 3.2.4 (or 7.3.2, for that matter). There was an issue that the 
properties of the current instance of a subtype aren't well-defined; that's 
the issue of AI12-0068-1. We expect this will end up as conservative as 
possible (the current instance is a value, not an object), but it hasn't be 
resolved yet. (It's on Tucker's homework list, but he didn't get to it 
before the last meeting.)

                                        Randy.


  reply	other threads:[~2014-05-12 22:26 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-05-12 12:54 Shouldn't there be a paragraph like 7.3.2(5/3) in 3.2.4? Jacob Sparre Andersen
2014-05-12 16:09 ` Adam Beneschan
2014-05-12 22:26   ` Randy Brukardt [this message]
2014-05-13  8:53     ` Jacob Sparre Andersen
replies disabled

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