Boost logo

Boost Users :

Subject: [Boost-users] lexical_cast<> in 1.39 does not provide basic_stringstream to operator>>
From: Max Motovilov (max_at_[hidden])
Date: 2011-01-27 13:33:12


Just ran into a regression in old code that last worked [probably] with
1.32 -- I have a number of ADTs which use tellg()/seekg() in their
implementations of operator>>. This used to work fine with lexical_cast
and now it breaks because the [optimized?] version in 1.39 uses a
statically allocated buffer and plain Jane basic_streambuf which does
not implement seekpos() and seekoff(). According to
http://www.boost.org/doc/libs/1_45_0/libs/conversion/lexical_cast.htm#n1973,
operator>> called from a lexical_cast should have at least
basic_stringbuf to work with.

Now, this project is locked into 1.39 for administrative reasons and I
will have to work around the issue anyway. Still, I'm curious whether
this is a problem that has been fixed since 1.39, a previously unnoticed
bug or a by-design behavior that I am misinterpreting as a violation of
spec...

Thanks in advance,
...Max...


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net