https://gcc.gnu.org/bugzilla/show_bug.cgi?id=59267
--- Comment #5 from Jonathan Wakely <redi at gcc dot gnu.org> --- (In reply to James from comment #3) > 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?): No. Again, this is doing exactly what the standard says it should.