(Serialization) Serialization for enable_shared_from_this

Alexander Gutenev wrote a message concerning this problem on Dec. 14, and I have a similar problem, also with Boost 1.41 and 1.42. After spending some time looking at this, the problem seems to be caused by creating the shared_ptr as a shared_ptr to void. This causes the shared_ptr constructor that does not support enabled_shared_from_this to be called. I think that this is because the constructor is called from a place (shared_ptr_helper.cpp) where the class derived from enable_shared_from_this is not complete. I was able to work around the problem by moving the construction of the shared_ptr back to the shared_ptr_helper::reset function template. It would really help if this problem could be fixed. It is likely that Alexander and I aren't the only ones that rely on this capability. Thank you, Carus V. (Bud) Clarke carus.v.clarke@boeing.com

Feel free to make track item for this. Robert Ramey Clarke, Carus V wrote:
Alexander Gutenev wrote a message concerning this problem on Dec. 14, and I have a similar problem, also with Boost 1.41 and 1.42. After spending some time looking at this, the problem seems to be caused by creating the shared_ptr as a shared_ptr to void. This causes the shared_ptr constructor that does not support enabled_shared_from_this to be called. I think that this is because the constructor is called from a place (shared_ptr_helper.cpp) where the class derived from enable_shared_from_this is not complete.
I was able to work around the problem by moving the construction of the shared_ptr back to the shared_ptr_helper::reset function template. It would really help if this problem could be fixed. It is likely that Alexander and I aren't the only ones that rely on this capability.
Thank you,
Carus V. (Bud) Clarke carus.v.clarke@boeing.com
participants (2)
-
Clarke, Carus V
-
Robert Ramey