re PR libstdc++/12657 (Resolution of DR 292 (WP) still unimplemented)
authorPaolo Carlini <pcarlini@suse.de>
Wed, 22 Oct 2003 15:44:19 +0000 (15:44 +0000)
committerPaolo Carlini <paolo@gcc.gnu.org>
Wed, 22 Oct 2003 15:44:19 +0000 (15:44 +0000)
2003-10-22  Paolo Carlini  <pcarlini@suse.de>

PR libstdc++/12657
* include/bits/basic_ios.tcc (copyfmt(const basic_ios&)):
Implement resolution of DR 292 (WP).
* docs/html/ext/howto.html: Add entry for DR 292.

From-SVN: r72803

libstdc++-v3/ChangeLog
libstdc++-v3/docs/html/ext/howto.html
libstdc++-v3/include/bits/basic_ios.tcc

index 3ac3f04ce385e50585cc6375d280f95a39e44183..7ee8180efe559be51febf8f2fdb7ad70fc2c09c9 100644 (file)
@@ -1,3 +1,10 @@
+2003-10-22  Paolo Carlini  <pcarlini@suse.de>
+
+       PR libstdc++/12657
+       * include/bits/basic_ios.tcc (copyfmt(const basic_ios&)):
+       Implement resolution of DR 292 (WP).
+       * docs/html/ext/howto.html: Add entry for DR 292.
+
 2003-10-21  Benjamin Kosnik  <bkoz@redhat.com>
 
        * include/ext/mt_allocator.h: Change include to gthr.h.
index 1c190a66613eaabf81b1422d357437ff7267e2ac..f9e7cb6e4d467f72175cf28660dfdb969381037e 100644 (file)
     <dd>Similar to 118.
     </dd>
 
+    <dt><a href="lwg-defects.html#292">292</a>:
+        <em>Effects of a.copyfmt (a)</em>
+    </dt>
+    <dd>If <code>(this == &amp;rhs)</code> do nothing.
+    </dd>
+
 <!--
     <dt><a href="lwg-defects.html#"></a>:
         <em></em>
index 9df5f4880e343f8dfaecc73341cc6d1ec4cb64dc..541453afb319b63322403383685c0ef15ac997af 100644 (file)
@@ -60,6 +60,11 @@ namespace std
     basic_ios<_CharT, _Traits>&
     basic_ios<_CharT, _Traits>::copyfmt(const basic_ios& __rhs)
     {
+      // _GLIBCXX_RESOLVE_LIB_DEFECTS
+      // 292. effects of a.copyfmt (a)
+      if (this == &__rhs)
+       return *this;
+
       // Per 27.1.1, do not call imbue, yet must trash all caches
       // associated with imbue()