diff src/oct-strstrm.h @ 4051:b79da8779a0e

[project @ 2002-08-17 19:38:32 by jwe]
author jwe
date Sat, 17 Aug 2002 19:38:33 +0000
parents 13905c3a24af
children 6cb22b9e3942
line wrap: on
line diff
--- a/src/oct-strstrm.h
+++ b/src/oct-strstrm.h
@@ -23,9 +23,10 @@
 #if !defined (octave_octave_strstream_h)
 #define octave_octave_strstream_h 1
 
-#include <strstream>
 #include <string>
 
+#include "lo-sstream.h"
+
 #include "oct-stream.h"
 
 class
@@ -114,7 +115,7 @@
 
 private:
 
-  std::istrstream is;
+  ISSTREAM is;
 
   // No copying!
 
@@ -147,10 +148,9 @@
 
   std::string str (void)
     {
-      os << std::ends;
-      char *tmp = os.str ();
-      std::string retval = tmp;
-      delete [] tmp;
+      os << OSSTREAM_ENDS;
+      std::string retval = OSSTREAM_STR (os);
+      OSSTREAM_FREEZE (os);
       return retval;
     }
 
@@ -166,7 +166,7 @@
 
 private:
 
-  std::ostrstream os;
+  OSSTREAM os;
 
   // No copying!