
Hugh Hoover wrote:
On May 20, 2006, at 09:16, Robert Ramey wrote:
Hugh Hoover wrote:
I note that the boost cvs tip version (for 1_34) also does not have an assert there. I'm not sure if that would have helped me figure out what was wrong, but at least an assert would terminate things closer to the source of the problem...
exactly where do you think the assert should go?
I think in boost::archive::detail::save_pointer_type<>::invoke (in oserializer.hpp) - right after it gets the bpos_ptr from register_type. I presume (but I'm not absolutely certain) that you should ALWAYS get back a valid bpos_ptr at this point?
I don't think so. It looks to me that a NULL bpos_ptr signfies an abstract class. and its not a mistake to serialize an abstract class - (the system calls the actual derived classes).
Adding one of those "you might have made this mistake" comments at that point with something about BOOST_IS_ABSTRACT on a derived class would have shortened my debugging time by DAYS - but I'm not certain if that's the main reason for the failure or if anything else could cause that kind of failure?
I'm not sure which compiler your using - but some implement is_abstract correctly - obviating the need for BOOST_IS_ABSTRACT. Maybe that's helpful. Robert Ramey
Anyway - thanks for the quick reply and all of the excellent work!
Hugh Hoover Enumclaw Software