CVS difference for ai05s/ai05-0214-1.txt

Differences between 1.5 and version 1.6
Log of other versions for file ai05s/ai05-0214-1.txt

--- ai05s/ai05-0214-1.txt	2011/02/11 04:31:19	1.5
+++ ai05s/ai05-0214-1.txt	2011/02/16 06:15:23	1.6
@@ -82,13 +82,15 @@
 since currently such types, if they have defaulted discriminants, can
 have objects for which 'Constrained is False. (Though currently some
 compilers return True for 'Constrained of such objects, so clearly this
-is not a thoroughly tested "feature" of the language.) This does imply
-that the value of the 'Constrained attribute could be used to discover
-whether the type of a parameter is tagged "deep down," even though that
-is not visible at the point of the use of the attribute. In this sense,
-preserving the rule that tagged objects always have 'Constrained of True
-provides a way to break privacy, though only at run-time (which is not
-usually considered an issue).
+is not a thoroughly tested "feature" of the language.) Note that this
+property is determined by the full view of a type, never the partial view
+of a type, as this is a runtime property -- therefore privacy is irrelevant.
+This does imply that the value of the 'Constrained attribute could be used to
+discover whether the full type of a parameter is tagged, even though that is not
+visible at the point of the use of the attribute -- but this cannot be done
+reliably (you can tell whether the full type of a parameter is untagged,
+but not whether it is tagged, unless there is cooperation from the caller of the
+routine).
 
 !example
 
@@ -435,6 +437,56 @@
 point it would be more reliable to just read the source code. :-) Since the
 "break privacy" statement seems scary, and it isn't really able to tell you
 anything, I think you should just drop that whole point.
+
+****************************************************************
+
+From: Tucker Taft
+Date: Friday, February 11, 2011  9:11 AM
+
+I mentioned it because this was essentially the issue that Gary had qualms
+about.  I can drop it, but it seems like something that will come up when people
+consider some of the quirks inherent in this approach.
+
+****************************************************************
+
+From: Randy Brukardt
+Date: Friday, February 11, 2011  12:54 PM
+
+I should let Gary explain this himself, but I don't recall him having any such
+qualms. I thought his issue was the inconsistency between partial and full views
+- and that doesn't happen with these rules (this is solely runtime, which is
+never view-based).
+
+If we do need to talk about it, we need to avoid scary phrases like "breaking
+privacy", because there is no privacy at runtime. Something more like "Note that
+this property is determined by the full view of a type, never the partial view
+of a type, as this is a runtime property (thus privacy is irrelevant)."
+
+****************************************************************
+
+From: Gary Dismukes
+Date: Friday, February 11, 2011  4:25 PM
+
+> I should let Gary explain this himself, but I don't recall him having
+> any such qualms. I thought his issue was the inconsistency between
+> partial and full views - and that doesn't happen with these rules
+> (this is solely runtime, which is never view-based).
+
+I think I initially had concerns that the semantics were different depending on
+whether the view was partial or full (and maybe about that implying some
+distributed overhead), but that confusion was cleared up.  I also noted that
+GNAT was treating the limited private case based on the "constraindness" of the
+partial view, so could return False for 'Constrained even though the full type
+was tagged, rather than using the full (run-time) view.
+
+> If we do need to talk about it, we need to avoid scary phrases like
+> "breaking privacy", because there is no privacy at runtime. Something
+> more like "Note that this property is determined by the full view of a
+> type, never the partial view of a type, as this is a runtime property
+> (thus privacy is irrelevant)."
+
+I think that's a reasonable way to phrase it, so would support revising the AARM
+paragraph along those lines.
 
 ****************************************************************
 

Questions? Ask the ACAA Technical Agent