Boost logo

Boost Users :

Subject: [Boost-users] Serialization: how to port binary archives containing NAN created with version 1.43 to version 1.47?
From: Terry McLendive (tmclendive_at_[hidden])
Date: 2011-08-19 09:34:40


Hi everyone,

I am encountering a particularly gnarly version of the
backward-compatibility problem with binary archives that others have
discovered (here:
http://groups.google.com/group/boost-list/browse_thread/thread/f4e3287f6925fc41,
for example).

Specifically, I have a number of binary archives created with version 1.43
of the library that are unreadable using version 1.47. I'd like to "port"
them forward, so my initial plan was to compile a simple translator program
against the 1.43 library that would read the binary archives and save them
as (1.43) text archives. Then, a second program compiled against the 1.47
library would read the text archives and save them as (1.47) binary. Easy
peasy.

Except: the archives contain NAN values, which work fine when everything is
binary but fail to deserialize for any version of the library when the
archive is text (or xml, apparently), for reasons I don't quite understand.

So my question is: how can I take my (1.43) binary archives containing NAN
values and get them into a format readable by the current (1.47) version of
the library? Is it possible?

Thanks,

Terry

(An aside: it seems strange that I'm allowed to serialize a NAN to text, but
it breaks when I try to deserialize it... why not prevent the creation of
un-deserializable archives at the point of serialization?).



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