CVS difference for ais/ai-10260.txt

Differences between 1.5 and version 1.6
Log of other versions for file ais/ai-10260.txt

--- ais/ai-10260.txt	2004/12/09 19:55:39	1.5
+++ ais/ai-10260.txt	2005/01/07 03:07:46	1.6
@@ -8,7 +8,7 @@
 !standard  3.09.02 (02)
 !standard  3.09.03 (03)
 !standard  3.09.03 (11)
-!standard 12.06  (03)
+!standard 12.06  (02)
 !standard 12.06  (04)
 !standard 12.06  (08)
 !standard 12.06  (10)
@@ -81,10 +81,10 @@
 
 Add after 3.9(18):
 
-The following language-defined generic functions exist:
+The following language-defined generic function exists:
 
     generic
-        type T (<>) is abstract tagged private;
+        type T (<>) is abstract tagged limited private;
         type Parameters (<>) is limited private;
         with function Constructor (Params : access Parameters)
             return T is abstract;
@@ -94,26 +94,17 @@
     pragma Preelaborate (Generic_Dispatching_Constructor);
     pragma Convention (Intrinsic, Generic_Dispatching_Constructor);
 
-    generic
-        type T (<>) is abstract tagged limited private;
-        type Parameters (<>) is limited private;
-        with function Constructor (Params : access Parameters)
-             return T is abstract;
-    function Ada.Tags.Generic_Limited_Dispatching_Constructor
-       (The_Tag : Tag;
-        Params : access Parameters) return T'Class;
-    pragma Preelaborate (Generic_Limited_Dispatching_Constructor);
-    pragma Convention (Intrinsic, Generic_Limited_Dispatching_Constructor);
-
-Tags.Generic_Dispatching_Constructor and Tags.Generic_Limited_Dispatching_Constructor
-provide a mechanism to create an object of an appropriate type from just a tag
+Tags.Generic_Dispatching_Constructor
+provides a mechanism to create an object of an appropriate type from just a tag
 value. The function Constructor is expected to create the object given a
 reference to an object of type Parameters.
 
-AARM Note: This specification is designed to make it easy to create dispatching
-constructors for streams; in particular, this can be used to construct
-overridings for T'Class'Input.
+AARM Notes: This specification is designed to make it easy to create
+dispatching constructors for streams; in particular, this can be used to
+construct overridings for T'Class'Input.
 
+Note that any tagged type will match type T (see 12.5.1).
+End AARM Notes.
 
 Add after 3.9(25):
 
@@ -123,9 +114,8 @@
 [Editor's Note: If AI-344 is included in the Amendment, this rule should
 include Descendant_Tag and Is_Descendant_At_Same_Level.]
 
-An instance of Tags.Generic_Dispatching_Constructor or
-Tags.Generic_Limited_Dispatching_Constructor raises Tag_Error if The_Tag does not
-represent a concrete descendant of T.
+An instance of Tags.Generic_Dispatching_Constructor raises Tag_Error if
+The_Tag does not represent a concrete descendant of T.
 Otherwise, it dispatches to the primitive function denoted by the formal
 Constructor for the type identified by the tag The_Tag, passing Params, and
 returns the result. Any exception raised by the function is propagated.
@@ -137,9 +127,9 @@
 
 Erroneous Execution
 
-If the internal tag provided to an instance of Tags.Generic_Dispatching_Constructor
-or Tags.Generic_Limited_Dispatching_Constructor identifies a specific type whose tag
-has not been elaborated, or does not exist in the partition at the time of the
+If the internal tag provided to an instance of
+Tags.Generic_Dispatching_Constructor identifies a specific type whose tag has
+not been elaborated, or does not exist in the partition at the time of the
 call, execution is erroneous.
 
 AARM Note: For a library-level type, this shouldn't be possible presuming that
@@ -154,8 +144,8 @@
 
 Add after 3.9(30):
 
-The capability provided by Tags.Generic_Dispatching_Constructor and
-Tags.Generic_Limited_Dispatching_Constructor is sometimes known as a factory.
+The capability provided by Tags.Generic_Dispatching_Constructor is
+sometimes known as a factory.
 
 Change the first sentence of 3.9.2(1):
 
@@ -181,12 +171,12 @@
 
 Replace 12.6(2) by:
 
-formal_subprogram_declaration ::= formal_abstract_subprogram_declaration |
-	formal_concrete_subprogram_declaration
+formal_subprogram_declaration ::= formal_abstract_subprogram_declaration
+   | formal_concrete_subprogram_declaration
 formal_concrete_subprogram_declaration ::=
-        with subprogram_specification [is subprogram_default];
+     with subprogram_specification [is subprogram_default];
 formal_abstract_subprogram_declaration ::=
-        with subprogram_specification is abstract [subprogram_default];
+     with subprogram_specification is abstract [subprogram_default];
 
 Add after 12.6(8):
 
@@ -215,10 +205,14 @@
 
 The actual subprogram for a formal_abstract_subprogram_declaration shall be a
 dispatching operation of the controlling type or of the actual type
-corresponding to the controlling type of the
-formal_abstract_subprogram_declaration.
+corresponding to the controlling type.
+
+AARM Note:
+To Be Honest: We mean the controlling type of the
+formal_abstract_subprogram_declaration, of course. Saying that gets unwieldy
+and redundant.
 
-AARM Note: This means that it is either a primitive operation of the
+This means that it is either a primitive operation of the
 controlling type, or an abstract formal subprogram. Also note that this
 prevents the controlling type from being class-wide,
 as only specific types have primitive operations (and a formal subprogram
@@ -599,10 +593,10 @@
 @xhang<@xterm<X'Tag>
 X'Tag denotes the tag of X. The value of this attribute is of type Tag.>
 @dinss
-The following language-defined generic functions exist:
+The following language-defined generic function exists:
 
 @xcode<@b<generic>
-    @b<type> T (<@>) @b<is abstract tagged private>;
+    @b<type> T (<@>) @b<is abstract tagged limited private>;
     @b<type> Parameters (<@>) @b<is limited private>;
     @b<with function> Constructor (Params : @b<access> Parameters)
         @b<return> T @b<is abstract>;
@@ -610,21 +604,10 @@
    (The_Tag : Tag;
     Params : @b<access> Parameters) @b<return> T'Class;
 @b<pragma> Preelaborate (Generic_Dispatching_Constructor);
-@b<pragma> Convention (Intrinsic, Generic_Dispatching_Constructor);
-
-@b<generic>
-    @b<type> T (<@>) @b<is abstract tagged limited private>;
-    @b<type> Parameters (<@>) @b<is limited private>;
-    @b<with function> Constructor (Params : @b<access> Parameters)
-        @b<return> T @b<is abstract>;
-@b<function> Ada.Tags.Generic_Limited_Dispatching_Constructor
-   (The_Tag : Tag;
-    Params : @b<access> Parameters) @b<return> T'Class;
-@b<pragma> Preelaborate (Generic_Limited_Dispatching_Constructor);
-@b<pragma> Convention (Intrinsic, Generic_Limited_Dispatching_Constructor);>
+@b<pragma> Convention (Intrinsic, Generic_Dispatching_Constructor);>
 
-Tags.Generic_Dispatching_Constructor and Tags.Generic_Limited_Dispatching_Constructor
-provide a mechanism to create an object of an appropriate type from just a tag
+Tags.Generic_Dispatching_Constructor
+provides a mechanism to create an object of an appropriate type from just a tag
 value. The function Constructor is expected to create the object given a
 reference to an object of type Parameters.
 
@@ -637,8 +620,8 @@
 Tag_Error is raised by a call of Expanded_Name, External_Tag, or Parent_Tag if
 any tag passed is No_Tag.
 
-An instance of Tags.Generic_Dispatching_Constructor or
-Tags.Generic_Limited_Dispatching_Constructor raises Tag_Error if The_Tag does not
+An instance of Tags.Generic_Dispatching_Constructor
+raises Tag_Error if The_Tag does not
 represent a concrete descendant of T.
 Otherwise, it dispatches to the primitive function denoted by the formal
 Constructor for the type identified by the tag The_Tag, passing Params, and
@@ -647,8 +630,7 @@
 @i<@s8<Erroneous Execution>>
 
 If the internal tag provided to an instance of
-Tags.Generic_Dispatching_Constructor or
-Tags.Generic_Limited_Dispatching_Constructor identifies a specific type whose
+Tags.Generic_Dispatching_Constructor identifies a specific type whose
 tag has not been elaborated, or does not exist in the partition at the time of
 the call, execution is erroneous.
 
@@ -663,8 +645,7 @@
 declared (see 3.10.1).>>
 @dinst
 @xindent<@s9<66  The capability provided by
-Tags.Generic_Dispatching_Constructor and
-Tags.Generic_Limited_Dispatching_Constructor is sometimes known as a
+Tags.Generic_Dispatching_Constructor is sometimes known as a
 @i<factory>.>>
 
 !corrigendum 3.9.2(1)
@@ -752,12 +733,20 @@
 @drepl
 @xcode<@fa<formal_subprogram_declaration ::= >@ft<@b<with>>@fa< subprogram_specification [>@ft<@b<is>>@fa< subprogram_default];>>
 @dby
-@xcode<@fa<formal_subprogram_declaration ::= formal_abstract_subprogram_declaration |
-	formal_concrete_subprogram_declaration
+@xcode<@fa<formal_subprogram_declaration ::= formal_abstract_subprogram_declaration
+   | formal_concrete_subprogram_declaration
 formal_concrete_subprogram_declaration ::=
-        >@ft<@b<with>>@fa< subprogram_specification [>@ft<@b<is>>@fa< subprogram_default];
+     >@ft<@b<with>>@fa< subprogram_specification [>@ft<@b<is>>@fa< subprogram_default];
 formal_abstract_subprogram_declaration ::=
-        >@ft<@b<with>>@fa< subprogram_specification >@ft<@b<is abstract>>@fa< [subprogram_default];>>
+     >@ft<@b<with>>@fa< subprogram_specification >@ft<@b<is abstract>>@fa< [subprogram_default];>>
+
+!corrigendum 12.6(04)
+!comment to force a conflict with null procedures, so we can disallow them for these.
+
+@drepl
+@xcode<@fa<default_name ::= name>>
+@dby
+@xcode<@fa<default_name ::= name>>
 
 !corrigendum 12.6(08)
 
@@ -777,8 +766,7 @@
 
 The actual subprogram for a @fa<formal_abstract_subprogram_declaration> shall
 be a dispatching operation of the controlling type or of the actual type
-corresponding to the controlling type of the
-@fa<formal_abstract_subprogram_declaration>.
+corresponding to the controlling type.
 
 !corrigendum 12.6(10)
 

Questions? Ask the ACAA Technical Agent