$include_dir="/home/hyper-archives/boost-users/include"; include("$include_dir/msg-header.inc") ?>
Subject: Re: [Boost-users] [serialization] Object reference tracking on instances bug?
From: r_at_[hidden]
Date: 2017-02-07 14:44:32
> It does serialize the first reference to the object correctly, but
> later objects just use the object_id_reference if they were similar
> to
> the first one (even if they contain different data!). So the first
> color is serialized correctly.
The saving machinery kicks in at
boost/archive/detail/oserializer.hpp
on line 510. That is where it selects, at compile time, wether the
object to serialize is a pointer, enum, "array", or regular non-pointer
type. In your case, I'm guessing it should always select the regular
non-pointer overload. You can add a breakpoint there and start your
debugger to see if it does the correct thing. Can you try that?
Regards,
Raoul