CVS difference for ai12s/ai12-0183-1.txt

Differences between 1.9 and version 1.10
Log of other versions for file ai12s/ai12-0183-1.txt

--- ai12s/ai12-0183-1.txt	2018/05/18 01:58:46	1.9
+++ ai12s/ai12-0183-1.txt	2018/06/12 03:08:49	1.10
@@ -1,7 +1,8 @@
-!standard 3.7.2(3/3)                                    17-11-21  AI12-0183-1/05
+!standard 3.7.2(3/3)                                    18-06-11  AI12-0183-1/06
 !standard 4.9(2)
 !standard 5.5.2(5/5)
 !standard 8.3(12.3/2)
+!standard 12.6(8.2/2)
 !standard D.4(4)
 !standard D.4(7/5)
 !standard E.4(17)
@@ -32,6 +33,8 @@
 
 7) E.4(17) ought to reference 9.5, not 9.5.1.
 
+8) 12.6(8.2/2) should say subprogram rather than object.
+
 !question
 
 1) AI12-0163-1 defines policy Ordered_FIFO_Queuing. But the Legality Rule
@@ -67,6 +70,14 @@
 operations (see 9.5.1)." But The definition of "potentially blocking" was
 moved to 9.5. The reference ought to be changed, right? (Yes.)
 
+8) 12.6(8.2/2) starts:
+
+ * if the actual matching the formal_subprogram_declaration denotes a 
+   generic formal object of another generic unit G ...
+
+But a formal object never matches a formal subprogram. Is this supposed to say
+"subprogram" rather than "object"? (Yes.)
+
 !recommendation
 
 (See Summary.)
@@ -118,6 +129,15 @@
    All forms of remote subprogram calls are potentially blocking operations
    (see {9.5}[9.5.1]). 
 
+8) Modify 12.6(8.2/2):
+
+  * if the actual matching the formal_subprogram_declaration denotes a generic
+    formal {subprogram}[object] of another generic unit G, and the
+    instantiation containing the actual [that] occurs within the body of a 
+    generic unit G or within the body of a generic unit declared within the
+    declarative region of the generic unit G, then the corresponding parameter
+    or result type of the formal subprogram of G shall have a null_exclusion;
+
 !discussion
 
 1) This is a clear omission from AI12-0163-1. Obviously, if we define a queuing
@@ -161,6 +181,12 @@
 
 7) The reference clearly ought to be corrected.
 
+8) This is clearly a cut-and-paste error; there is a very similar rule in 12.4
+for formal objects and it appears too much was copied. There'd be no reason
+for a rule that starts "if False then", so we conclude that "subprogram" had
+to be intended. A respondent noted that there is also an extra "that" in the
+paragraph.
+
 !corrigendum 3.7.2(3)
 
 @drepl
@@ -218,6 +244,25 @@
 homographs are all fully conformant with one another, one is chosen
 arbitrarily; if not, they are all hidden from all visibility.>
 
+!corrigendum 12.6(8.2/2)
+
+@drepl
+@xbullet<if the actual matching the @fa<formal_subprogram_declaration>
+denotes a generic formal object of another generic unit @i<G>, and the
+instantiation containing the actual that occurs within the body
+of a generic unit @i<G> or within the body of a generic unit declared within
+the declarative region of the generic unit @i<G>, then the corresponding
+parameter or result type of the formal subprogram of @i<G> shall have a
+@fa<null_exclusion>;>
+@dby
+@xbullet<if the actual matching the @fa<formal_subprogram_declaration>
+denotes a generic formal subprogram of another generic unit @i<G>, and the
+instantiation containing the actual occurs within the body
+of a generic unit @i<G> or within the body of a generic unit declared within
+the declarative region of the generic unit @i<G>, then the corresponding
+parameter or result type of the formal subprogram of @i<G> shall have a
+@fa<null_exclusion>;>
+
 !corrigendum D.4(4)
 
 @drepl
@@ -319,6 +364,100 @@
 occurrences of the word "iterator"!), and immediately made the correction (as
 is the usual policy for presentation changes). [We'll vote on that AI
 someday, but there's no rush.]
+
+****************************************************************
+
+From: Randy Brukardt
+Sent: Friday, June 8, 2018  10:48 PM
+
+12.6(8.1/2 and 8.2/2) say:
+
+For a parameter or result subtype of a formal_subprogram_declaration that has 
+an explicit null_exclusion:
+
+* if the actual matching the formal_subprogram_declaration denotes a generic 
+  formal object of another generic unit G, and the instantiation containing
+  the actual that occurs within the body of a generic unit G or within the 
+  body of a generic unit declared within the declarative region of the generic
+  unit G, then the corresponding parameter or result type of the formal 
+  subprogram of G shall have a null_exclusion;
+
+---
+
+What generic formal object is being talked about here? I thought that the 
+actual of a formal subprogram had to be a subprogram (duh!).
+
+I note this wording is very similar to the wording for formal objects, so 
+perhaps the use of "object" here is just a cut-and-paste error. But it goes
+back to the original Ada 2005 AI (AI95-00423-01) and thus no one has 
+questioned it for 12+ years. (It's conceivable that no one ever tried to 
+implement this rule, as there is no ACATS test and it would be easy to forget
+about. I was working toward ensuring that neither statement is true, but got 
+hung up on this wording.)
+
+My guess, therefore is that "object" should be "subprogram" in this wording; 
+that would make a lot more sense. Agree or disagree??
+
+Assuming no one disagrees, I'll just stick this into the presentation AI, 
+since it *seems* like an obvious cut-and-paste bug. (But I wanted to check
+if others agree.)
+
+****************************************************************
+
+From: Tucker Taft
+Sent: Saturday, June 9, 2018  2:46 PM
+
+> 12.6(8.1/2 and 8.2/2) say:
+> 
+> For a parameter or result subtype of a formal_subprogram_declaration 
+> that has an explicit null_exclusion:
+> 
+> * if the actual matching the formal_subprogram_declaration denotes a 
+> generic formal object of another generic unit G, and the instantiation 
+> containing the actual that occurs within the body of a generic unit G 
+> or within the
+                     ^^^^^^^^^
+This sentence is not only long, but seems to have an extra "that".
+
+> body of a generic unit declared within the declarative region of the 
+> generic unit G, then the corresponding parameter or result type of the 
+> formal subprogram of G shall have a null_exclusion;
+> 
+> ---
+> 
+> What generic formal object is being talked about here? I thought that 
+> the actual of a formal subprogram had to be a subprogram (duh!).
+> 
+> I note this wording is very similar to the wording for formal objects, 
+> so perhaps the use of "object" here is just a cut-and-paste error. But 
+> it goes back to the original Ada 2005 AI (AI95-00423-01) and thus no 
+> one has questioned it for 12+ years. (It's conceivable that no one 
+> ever tried to implement this rule, as there is no ACATS test and it 
+> would be easy to forget about. I was working toward ensuring that 
+> neither statement is true, but got hung up on this wording.)
+> 
+> My guess, therefore is that "object" should be "subprogram" in this 
+> wording; that would make a lot more sense. Agree or disagree??
+
+Agree.  The last sentence of the above quote refers to "the formal subprogram
+of G" so that clearly indicates that the earlier reference should have said
+"... denotes a generic formal subprogram of another generic unit G, ..."
+
+Also, as mentioned above, I believe the sentence has an extra "that."  Hence, 
+I believe it should be:
+
+  * if the actual matching the formal_subprogram_declaration denotes a generic
+    formal subprogram of another generic unit G, and the instantiation containing
+    the actual occurs within the body of a generic unit G or within the
+    body of a generic unit declared within the declarative region of the generic
+    unit G, then the corresponding parameter or result type of the formal
+    subprogram of G shall have a null_exclusion;
+
+> Assuming no one disagrees, I'll just stick this into the presentation 
+> AI, since it *seems* like an obvious cut-and-paste bug. (But I wanted 
+> to check if others agree.)
+
+Make sense.
 
 ***************************************************************
 

Questions? Ask the ACAA Technical Agent