
Rico wrote:
My program consists of only one Dll which contains all classes and its serialization code.
I implemented the serialization the way Robert suggested:
in the header: class mytype { ... template<class Archive> serialize(Archive &ar, const unsigned int version); ...};
in the dll
template class::serialize(text_iarchive & ar, const unsigned version){ ... ar << ... ... };
There is no serialization code in any header. I just call the serialization from the main program, but there is no duplicated code.
And you still have the crash? - maybe I'm wrong about the cause. Or maybe my advice doesn't go far enough. using something like ar << x // where x is an type mytype * in the mainline while the dll contains similar code might also create problems. I'd have to think about this some more? Robert Ramey
What do I have to change to avoid the crash?