This is the mail archive of the libstdc++@sourceware.cygnus.com mailing list for the libstdc++ project.


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

Re: strstream bug



Igor, 

v-3 uses the standard approved stringstreams. Thus you can do stuff like:

#include <iostream>
#include <sstream>

int main() 
{
  string s("012345678");
  istringstream sts(s);
  int i;
  sts >> i;
  cout << i << endl;

  return 0;
}

/*
gives you:
% a.out
12345678
*/


That should take care of your first bug. The second one is incomplete, and
I'm not quite sure what you'd expect (zero in == zero out)? In anycase, I
don't have overloaded insertion/extraction operators to test with.


Hope this helps,
Benjamin



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