CVS difference for ais/ai-00218.txt

Differences between 1.8 and version 1.9
Log of other versions for file ais/ai-00218.txt

--- ais/ai-00218.txt	2001/09/08 01:42:47	1.8
+++ ais/ai-00218.txt	2001/09/13 01:16:20	1.9
@@ -1,4 +1,4 @@
-!standard 8.3(9-13)                                   01-09-07  AI95-00218/06
+!standard 8.3(9-13)                                   01-09-11  AI95-00218/06
 !standard 6.1(1)
 !class amendment 99-03-23
 !status ARG approved 7-0-1  01-05-18
@@ -29,9 +29,9 @@
 with Root;
 package Leaf is
    type Derived_Type is new Root.Root_Type with null record;
-   procedure Do_Something (Object : in out Root_Type;
-                           Data : in Boolean);     -- (3)
-   procedure Finalise (Object : in out Root_Type); -- (4)
+   procedure Do_Something (Object : in out Derived_Type;
+                           Data : in Boolean);        -- (3)
+   procedure Finalise (Object : in out Derived_Type); -- (4)
         -- Note: Alternative spelling of "Finalize".
 end Leaf;
 
@@ -79,7 +79,7 @@
 Similarly, accidental overriding can be minimized if the Ada compiler knows
 that the programmer has declared all intentional overriding.
 
-Unfortunately, a complete solution to this problem will be incompatible with
+Unfortunately, a complete solution to this problem would be incompatible with
 existing Ada 95 code. Therefore, we have to introduce an optional solution
 which applies only when the programmer asks for it.
 
@@ -87,12 +87,13 @@
 Optional_Overriding. Explicit_Overriding is a configuration pragma which
 requires explicit marking of overriding subprograms. Pragma Overriding is used
 to mark subprograms that are overriding. Pragma Optional_Overriding marks
-subprograms which may or may not be overriding. Unmarked subprograms are new
-declarations, and may not override another routine.
+subprograms which may or may not be overriding. Unmarked subprograms to
+which pragma Explicit_Overriding applies are new declarations and must not
+override another routine.
 
 !wording
 
-Add to 8.3 after paragraph 1:
+Add to 8.3 after paragraph 26:
 
 The form of a pragma Explicit_Overriding is as follows:
 
@@ -106,16 +107,14 @@
 
 pragma Optional_Overriding [(designator)];
 
-Add to 8.3 after paragraph 26:
-
 Pragma Explicit_Overriding is a configuration pragma.
 
 Pragmas Overriding and Optional_Overriding shall immediately follow (except
-for other pragmas) the declaration of a primitive operation. The optional
-designator of a pragma Overriding or Optional_Overriding shall be the same as
-the designator of the operation which it follows. Only one of the pragmas
-Overriding and Optional_Overriding shall be given for a single primitive
-operation.
+for other pragmas) the explicit declaration of a primitive operation. The
+optional designator of a pragma Overriding or Optional_Overriding shall be
+the same as the designator of the operation which it follows. Only one of
+the pragmas Overriding and Optional_Overriding shall be given for a single
+primitive operation.
 
 A primitive operation to which pragma Overriding applies shall override another
 operation. In addition to the places where Legality Rules normally
@@ -126,7 +125,7 @@
 compilation units to which it applies, except that in an instance of a generic
 unit, Explicit_Overriding applies if and only if it applies to the generic
 unit. At a place where a pragma Explicit_Overriding applies, an explicit
-subprogram_declaration to which neither pragma Overriding or
+subprogram_declaration to which neither pragma Overriding nor
 Optional_Overriding applies shall not be an overriding declaration. In
 addition to the places where Legality Rules normally apply, this rule also
 applies in the private part of an instance of a generic unit.
@@ -208,10 +207,10 @@
 accidentally separated from the subprogram declaration. The optional
 designator in the pragma provides a means to ensure that this does not happen.
 
-The chosen semantics means that the pragmas can be treated almost as a part of
+The chosen semantics mean that the pragmas can be treated almost as a part of
 the subprogram declaration. This eases the implementation, as a compiler can
-determine what kind of declaration it is processing before it starts doing so.
-(Without this rule, an implementation must postpone error messages until it
+determine what kind of declaration it is processing before it starts processing
+it. (Without this rule, an implementation must postpone error messages until it
 reaches the next declaration. Since the next declaration could be almost
 anything, this would provide a distributed overhead.)
 
@@ -255,8 +254,9 @@
 
 The pragmas Overriding and Optional_Overriding are checked in a
 generic_declaration. We do this because we do not want these pragmas to be
-part of the "contract" of a generic. To see how this could happen, consider
-the following example:
+part of the "contract" of a generic. That is, we do not want these pragmas
+to add additional restrictions on the actual parameters of the generic.
+To see how this could happen, consider the following example:
 
 generic
     type GT is tagged private;

Questions? Ask the ACAA Technical Agent