CVS difference for ais/ai-50217.txt

Differences between 1.10 and version 1.11
Log of other versions for file ais/ai-50217.txt

--- ais/ai-50217.txt	2003/10/29 00:39:32	1.10
+++ ais/ai-50217.txt	2003/11/27 02:01:16	1.11
@@ -1,4 +1,4 @@
-!standard 10.01.02   (04)                           03-10-08  AI95-00217-06/05
+!standard 10.01.02   (04)                           03-11-05  AI95-00217-06/06
 !standard 10.01.02   (06)
 !standard 10.01.04   (02)
 !standard 10.01.04   (03)
@@ -179,8 +179,8 @@
 o  in the same context_clause as a use_clause which names an entity declared
    within the declarative region of the library_item; or
 
-o  in the scope of a nonlimited_with_clause which mentions the same library_item;
-   or
+o  in the scope of a nonlimited_with_clause which mentions the same
+   library_item; or
 
 o  in the scope of a use_clause which names an entity declared within the
    declarative region of the library_item.
@@ -191,6 +191,18 @@
 The mechanisms for adding a unit mentioned in a limited_with_clause within an
 environment are implementation defined.
 
+
+Add at the end of 10.1.4(6):
+
+Before a compilation unit can be mentioned in a limited_with_clause, the
+implementation may require that it comply with:
+
+o  the syntax rules of the language; and
+
+o  the legality rule which forbids two non-overloadable homographs declared
+   immediately within the same declarative region.
+
+
 Add after 10.2(6):
 
 o  If the limited view of a unit is needed, then the full view of the unit is
@@ -230,7 +242,9 @@
 only includes nested packages and incomplete types.
 
 The changes to 10.1.2(8) ensure that, if for instance the specification of Q
-has a "with P.R", it shall not have a "limited with P" or a "limited with P.R". The same applies to the children of Q. On the other hand, a "limited with P.R.S" is fine.
+has a "with P.R", it shall not have a "limited with P" or a "limited with P.R".
+The same applies to the children of Q. On the other hand, a "limited with
+P.R.S" is fine.
 
 The fact that a "limited with P" hides the full view of P from all visibility
 prevents ripple effects. If you are is the scope of a "limited with P", the
@@ -347,6 +361,27 @@
 renaming, because that would require all kinds of semantic analysis stuff, such
 as visibility.
 
+An implementation need not create the limited view of a unit if that unit is
+"really broken". For instance, the limited view of P may not be created if the
+compiler is given the unit:
+
+   package Bad is
+      type T is new Integer;
+      type T is new Float;
+   end Bad;
+
+and even if the limited view is created, clients may still be rejected in an
+implementation defined manner. For the following unit might be rejected:
+
+   limited with Bad;
+   package Client is
+      type A is access Bad.T;
+   end Client;
+
+This is not different from the current state of affairs with normal withs,
+except that we need a specific rule because the limited view is not covered by
+"inserted into the environment".
+
 The applicable nonlimited_ and limited_with_clauses determine (1) which
 entities are visible, (2) which dereferencing are legal and (3) what is the
 type of dereferences. In particular:
@@ -3561,7 +3596,7 @@
 -----------------
 Thoughts on the implementation of "limited with" in AdaMagic
 
-          $Revision: 1.10 $ $Date: 2003/10/29 00:39:32 $
+          $Revision: 1.11 $ $Date: 2003/11/27 02:01:16 $
 
 The "limited with" clause makes a "limited view"
 of a package visible in the compilation unit
@@ -5370,7 +5405,7 @@
 -----------------
 Thoughts on the implementation of "limited with" in AdaMagic
 
-          $Revision: 1.10 $ $Date: 2003/10/29 00:39:32 $
+          $Revision: 1.11 $ $Date: 2003/11/27 02:01:16 $
 
 The "limited with" clause makes a "limited view"
 of a package visible in the compilation unit

Questions? Ask the ACAA Technical Agent