Boost logo

Boost :

From: David Abrahams (dave_at_[hidden])
Date: 2006-05-02 16:48:29

"Robert Ramey" <ramey_at_[hidden]> writes:

> This is explained in the docmentation under
> Reference/Special Considerations/Exporting Class Serialization
> Robert Ramey

I have analyzed your issue and I believe there is a better way; one
that avoids the header ordering requirement. I have put together a
small demonstration, which is enclosed. This shows that we can
instantiate a class template (instantiator) for the exported class and
each archive that's been seen.

Then the only challenge is causing that class template instantiation
to actually instantiate executable code. Fortunately, I've recently
addressed that problem in changes to the serialization library. The
basics are in CVS at:


(Ignore the part that says BOOST_OLD_CONCEPT_SUPPORT), so we have the
technology. And if you use the function pointer technique of
BOOST_CONCEPT_ASSERT(( ... )) in boost/boost/concept/assert.hpp you'll
be able to use BOOST_CLASS_EXPORT on class template instances with
multiple arguments.

  BOOST_CLASS_EXPORT(foo<bar,baz>) // an error, today.

I hope all this is helpful.

Dave Abrahams
Boost Consulting

Boost list run by bdawes at, gregod at, cpdaniel at, john at