
It seems I should call both clear and str to get the right result. 2009/2/17 Bo Persson <bop@gmb.dk>
Bill David wrote:
2009/2/16 Dmitry Goncharov <dgoncharov@unison.com>
You should invoke m_ss.seekg(ios_base::beg) before each parsing. Also, be careful with to_tm(). It is buggy. See https://svn.boost.org/trac/boost/ticket/1859
But after I do that, both invocations report "do not understand". And why clear can't rewind it?
The function clear doesn't "rewind" the stream, it just clears the flags, like eof. The old stream content is still there.
Thanks, I have tried. If I don't call clear, the fail status will impact the later call to this logic.
Bo Persson
_______________________________________________ Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost