Boost logo

Boost-Commit :

From: technews_at_[hidden]
Date: 2008-02-19 14:34:08


Author: turkanis
Date: 2008-02-19 14:34:07 EST (Tue, 19 Feb 2008)
New Revision: 43325
URL: http://svn.boost.org/trac/boost/changeset/43325

Log:
stringstreams are no longer closable; the semantics of close() for these devices was illconsidered
Text files modified:
   trunk/boost/iostreams/categories.hpp | 4 ----
   trunk/boost/iostreams/close.hpp | 17 -----------------
   2 files changed, 0 insertions(+), 21 deletions(-)

Modified: trunk/boost/iostreams/categories.hpp
==============================================================================
--- trunk/boost/iostreams/categories.hpp (original)
+++ trunk/boost/iostreams/categories.hpp 2008-02-19 14:34:07 EST (Tue, 19 Feb 2008)
@@ -139,22 +139,18 @@
     { };
 struct istringstream_tag
     : input_seekable,
- closable_tag,
       istream_tag
     { };
 struct ostringstream_tag
     : output_seekable,
- closable_tag,
       ostream_tag
     { };
 struct stringstream_tag
     : dual_seekable,
- closable_tag,
       iostream_tag
     { };
 struct stringbuf_tag
     : dual_seekable,
- closable_tag,
       streambuf_tag
     { };
 struct generic_istream_tag

Modified: trunk/boost/iostreams/close.hpp
==============================================================================
--- trunk/boost/iostreams/close.hpp (original)
+++ trunk/boost/iostreams/close.hpp 2008-02-19 14:34:07 EST (Tue, 19 Feb 2008)
@@ -136,8 +136,6 @@
             iostreams::select<
                 mpl::not_< is_convertible<category, closable_tag> >,
                 any_tag,
- is_std_string_device<unwrapped>,
- stringstream_tag,
                 mpl::or_<
                     is_boost_stream<unwrapped>,
                     is_boost_stream_buffer<unwrapped>
@@ -187,21 +185,6 @@
 };
 
 template<>
-struct close_impl<stringstream_tag> {
- template<typename T>
- static void close(T& t)
- {
- t.str("");
- }
- template<typename T>
- static void close(T& t, BOOST_IOS::openmode which)
- {
- if (which == BOOST_IOS::out)
- t.str("");
- }
-};
-
-template<>
 struct close_impl<close_boost_stream> {
     template<typename T>
     static void close(T& t)


Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk