2009/05/10

Deserialization of Polymorphic Pointers does not work...

Deserialization of polymorphic pointers does not work...

Firstly, it is strange that BOOST_CLASS_EXPORT does not work, and seems no effects. text_iarchive throws unregistered class exception.

I understand that register_type is not necessary if I use the BOOST_CLASS_EXPORT; However, the register_type is called explicitly, the exception is not thrown. But, in the case with register_type, deserialized pointer's type is differ from its original object.

Boost.Serialization registers the entries at only first time and does not change those? Old version from Subversion, which has not refactered these derived classes, seem to work. Umm...

No comments:

How to set parameters to debugging program on Visual Studio 2019 with CMake

Solution: MSDN Sometimes the "Debug and Launch Settings for CMake" bottun is disabled. In this case, change to the target view. ...