Commits

king  committed df80f77

ENH: Added "ostringstream(const kwsys_stl::string& s)" and "void str(const kwsys_stl::string& s)" compatibility methods.

  • Participants
  • Parent commits 26a04de
  • Tags ParaView-2-0-0, ParaView-2-0-InstallSupport-pre 1
    1. ParaView-2-0-bp

Comments (0)

Files changed (1)

File GCC_XML/KWSys/kwsys_ios_sstream.h.in

 public:
   typedef ostrstream Superclass;
   ostringstream() {}
+  ostringstream(const kwsys_stl::string& s) { *this << s.c_str(); }
   kwsys_stl::string str()
     {
     ostringstream_cleanup cleanup(*this);
     const char* ptr = this->Superclass::str();
     return kwsys_stl::string(ptr?ptr:"", pcount);
     }
+  void str(const kwsys_stl::string& s)
+    {
+    this->~ostringstream();
+    new (this) ostringstream(s);
+    }
 private:
   ostringstream(const ostringstream&);
   void operator=(const ostringstream&);