[serializatrion] problems with 1.44

I think something was broken in Boost 1.44. This code fails to compile with 1.44, but compiles with 1.43 (MSVC 10.0): #include <boost/variant.hpp> #include <boost/serialization/variant.hpp> #include <boost/archive/binary_iarchive.hpp> #include <sstream> int main() { std::stringstream s; boost::archive::binary_iarchive ar(s); boost::variant<int, char> x; ar >> x; return 0; } e:\libraries\boost\boost\serialization\variant.hpp(139): error C3861: 'BOOST_SERIALIZATION_NVP': identifier not found Am I missing something or is it a bug?

On 8/19/2010 1:34 PM, Dmitry Vinogradov wrote:
If you change the include order to: #include <boost/archive/binary_iarchive.hpp> #include <boost/variant.hpp> #include <boost/serialization/variant.hpp> it works. My guess is that a include that's needed has been removed. Maybe I'll have a look later on to see if I can find it. Have a nice day, Stefan

On Thu, August 19, 2010 12:44 pm, Stefan van Kessel wrote:
We have applied the patch below in our boost build script to workaround this omission. It seems correct since serialization/variant.hpp does have a dependency on BOOST_SERIALIZATION_NVP but does not include it's definition. Regards, Adam --- boost/serialization/variant.hpp 2010-08-03 21:50:43.000000000 +0100 +++ boost/serialization/variant.hpp 2010-08-03 21:50:50.000000000 +0100 @@ -41,6 +41,7 @@ #include <boost/serialization/split_free.hpp> #include <boost/serialization/serialization.hpp> +#include <boost/serialization/nvp.hpp> namespace boost { namespace serialization {
participants (3)
-
Adam Butcher
-
Dmitry Vinogradov
-
Stefan van Kessel