http://gcc.gnu.org/bugzilla/show_bug.cgi?id=59267
--- Comment #3 from James <troomps01 at gmail dot com> --- Sorry about having a second comment in a row, but I was playing a bit more with this, and using a string stream as solely an output stream doesn't appear to update the stream pointer after outputting the value (shouldn't this also output a blank string for os?): #include <iostream> #include <sstream> using namespace std; int main(void) { stringstream os(""); double val = 3.14159; os << val; cout << "Value: " << val << ", out stream: " << os.str() << endl; return 0; }