Boost logo

Boost Users :

From: Joseph Turian (turian_at_[hidden])
Date: 2006-01-20 18:26:55


> There are at least 3 totally orthogonal issues here.

Yes, thank you for breaking it down. I believe we've isolated the
trickiness to c)

> a) Serialization of static variables. This is handled the same as any other
> variables. Tracking can be used to ensure that only unique copies of
> the variables are serialized.

I don't think this will be difficult for me to implement.

> b) Serialization of smart_ptr<int>. This would handled like seriliazation
> of
> another other type of smart pointer - except smart_ptr<T> can only
> be serialized if T is a tracked type. I showed how to use
> BOOST_STRONG_TYPE to make a type equivalent to an int
> which can be tracked and therefore be used as an argument
> to a serialized smart_ptr.

Yes, thank you for explaining that for me.

> c) Serializiation of contained pointers. This is common case handled
> by the library. The library considers and handles correctly the
> case where pointers are cyclic. I modified your code to show it
> compiles. (note there is also a test for cyclic pointers.)

Well, I see how your example compiles in the case of RAW cyclic pointers.
However, I cannot use raw pointers, and I don't know how to get it to
compile with cyclic smart pointers (specifically, boost::shared_ptr).
Was there something that I missed?

Thanks,

   Joseph

--
http://www.cs.nyu.edu/~turian/

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