This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[v3] Mention in the docs DR 103.


Hi,

sollicited by libstdc++/14410. Committing mainline and 3.4.

Paolo.

/////////////
2004-03-08  Paolo Carlini  <pcarlini@suse.de>

	* docs/html/ext/howto.html: Add entry for DR 103 [WP].
	* include/bits/stl_multiset.h: Add comment about DR 103.
	* include/bits/stl_set.h: Likewise.
diff -urN libstdc++-v3-orig/docs/html/ext/howto.html libstdc++-v3/docs/html/ext/howto.html
--- libstdc++-v3-orig/docs/html/ext/howto.html	2004-02-26 12:35:06.000000000 +0100
+++ libstdc++-v3/docs/html/ext/howto.html	2004-03-08 15:51:58.000000000 +0100
@@ -295,6 +295,15 @@
 	not required to set <code>gcount</code>).
     </dd>
 
+    <dt><a href="lwg-defects.html#103">103</a>:
+        <em>set::iterator is required to be modifiable, but this allows
+	    modification of keys.</em>
+    </dt>
+    <dd>For associative containers where the value type is the same as
+        the key type, both <code>iterator</code> and <code>const_iterator
+	</code> are constant iterators.
+    </dd>
+
     <dt><a href="lwg-defects.html#109">109</a>:
         <em>Missing binders for non-const sequence elements</em>
     </dt>
diff -urN libstdc++-v3-orig/include/bits/stl_multiset.h libstdc++-v3/include/bits/stl_multiset.h
--- libstdc++-v3-orig/include/bits/stl_multiset.h	2004-02-08 05:46:42.000000000 +0100
+++ libstdc++-v3/include/bits/stl_multiset.h	2004-03-08 15:47:43.000000000 +0100
@@ -128,6 +128,9 @@
       typedef typename _Alloc::const_pointer const_pointer;
       typedef typename _Alloc::reference reference;
       typedef typename _Alloc::const_reference const_reference;
+      // _GLIBCXX_RESOLVE_LIB_DEFECTS
+      // DR 103. set::iterator is required to be modifiable,
+      // but this allows modification of keys.
       typedef typename _Rep_type::const_iterator iterator;
       typedef typename _Rep_type::const_iterator const_iterator;
       typedef typename _Rep_type::const_reverse_iterator reverse_iterator;
diff -urN libstdc++-v3-orig/include/bits/stl_set.h libstdc++-v3/include/bits/stl_set.h
--- libstdc++-v3-orig/include/bits/stl_set.h	2004-02-08 05:46:42.000000000 +0100
+++ libstdc++-v3/include/bits/stl_set.h	2004-03-08 15:47:02.000000000 +0100
@@ -132,6 +132,9 @@
       typedef typename _Alloc::const_pointer const_pointer;
       typedef typename _Alloc::reference reference;
       typedef typename _Alloc::const_reference const_reference;
+      // _GLIBCXX_RESOLVE_LIB_DEFECTS
+      // DR 103. set::iterator is required to be modifiable,
+      // but this allows modification of keys.
       typedef typename _Rep_type::const_iterator iterator;
       typedef typename _Rep_type::const_iterator const_iterator;
       typedef typename _Rep_type::const_reverse_iterator reverse_iterator;

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]