Hello all,
This is a corollary to my recent question on serialisation of shred_ptrs
and polymorphic classes - I noted it in that thread but it may be lost
in the debris.
In an effort to get them to work, I have put in a
BOOST_CLASS_EXPORT_GUID in my base and derived classes. However, this
brings up a compilation error...
>>whole load of template faults then... (see below for full error list)
../boost_1_33_1/boost/archive/basic_xml_archive.hpp:66: error :
incomplete type 'boost::STATIC_ASSERTION_FAILURE< false>' used in nested
name specifier
../boost_1_33_1/boost/archive/basic_xml_archive.hpp:66: error : size of
array has non-integral type '<type error>'
Now looking at the code where the final error occurs, it says this is
usually down to an unspecified NVP - i.e. a serialisation of a data item
not in an nvp statements. However, all the classes involved do have this
correctly set up. I have one question on it though..
Should I do this in my derived class to include the base class
serialisation
ar & base_object<A>(*this)
Or should I do this
ar & base_object<A>(make_nvp("base", *this) )
Both give the same compile error
Or is there simply a problem with BOOST_CLASS_EXPORT_GUID that means
that it is emitting something that needs nvp wrapping but this isn't
being done?
James
Complete compile error dump for masochists
iwmmxt_le-g++ -c -o TextPanel.o TextPanel.cpp -O0 -Iinclude
-I../Renderer/include -I../GI/include -I../boost_1_33_1
-I../common/include -fPIC
../boost_1_33_1/boost/archive/basic_xml_oarchive.hpp: In member function
`void boost::archive::basic_xml_oarchive<Archive>::save_override(T&,
int) [with T = const LCPanel, Archive = boost::archive::xml_oarchive]':
../boost_1_33_1/boost/archive/detail/interface_oarchive.hpp:78:
instantiated from `Archive&
boost::archive::detail::interface_oarchive<Archive>::operator<<(T&)
[with T = const LCPanel, Archive = boost::archive::xml_oarchive]'
../boost_1_33_1/boost/archive/detail/interface_oarchive.hpp:86:
instantiated from `Archive&
boost::archive::detail::interface_oarchive<Archive>::operator&(T&) [with
T = LCPanel, Archive = boost::archive::xml_oarchive]'
include/TextPanel.hpp:115: instantiated from `void
LCTextPanel::serialize(Archive&, unsigned int) [with Archive =
boost::archive::xml_oarchive]'
../boost_1_33_1/boost/serialization/access.hpp:109: instantiated from
`static void boost::serialization::access::serialize(Archive&, T&,
unsigned int) [with Archive = boost::archive::xml_oarchive, T =
LCTextPanel]'
../boost_1_33_1/boost/serialization/serialization.hpp:81: instantiated
from `void boost::serialization::serialize(Archive&, T&, unsigned int)
[with Archive = boost::archive::xml_oarchive, T = LCTextPanel]'
../boost_1_33_1/boost/serialization/serialization.hpp:140:
instantiated from `void boost::serialization::serialize_adl(Archive&,
T&, unsigned int) [with Archive = boost::archive::xml_oarchive, T =
LCTextPanel]'
../boost_1_33_1/boost/archive/detail/oserializer.hpp:233: instantiated
from `boost::archive::detail::pointer_oserializer<T,
Archive>::pointer_oserializer() [with T = LCTextPanel, Archive =
boost::archive::xml_oarchive]'
../boost_1_33_1/boost/archive/detail/oserializer.hpp:198: instantiated
from `const boost::archive::detail::pointer_oserializer<LCTextPanel,
boost::archive::xml_oarchive>
boost::archive::detail::pointer_oserializer<LCTextPanel,
boost::archive::xml_oarchive>::instance'
../boost_1_33_1/boost/archive/detail/oserializer.hpp:190: instantiated
from `static const boost::archive::detail::pointer_oserializer<T,
Archive>& boost::archive::detail::pointer_oserializer<T,
Archive>::instantiate() [with T = LCTextPanel, Archive =
boost::archive::xml_oarchive]'
../boost_1_33_1/boost/archive/detail/oserializer.hpp:515: instantiated
from `const boost::archive::detail::basic_pointer_oserializer&
boost::archive::detail::instantiate_pointer_oserializer(Archive*, T*)
[with Archive = boost::archive::xml_oarchive, T = LCTextPanel]'
../boost_1_33_1/boost/serialization/export.hpp:83: instantiated from
`static void boost::archive::detail::export_impl::archive<Archive,
T>::o::invoke() [with Archive = boost::archive::xml_oarchive, T =
LCTextPanel]'
../boost_1_33_1/boost/serialization/export.hpp:105: instantiated from
`static void boost::archive::detail::export_impl::archive<Archive,
T>::instantiate() [with Archive = boost::archive::xml_oarchive, T =
LCTextPanel]'
../boost_1_33_1/boost/serialization/export.hpp:116: instantiated from
`static void boost::archive::detail::export_impl::for_each_archive<ASeq,
T>::instantiate() [with ASeq =
boost::mpl::list2<boost::archive::xml_oarchive,
boost::archive::xml_iarchive>, T = LCTextPanel]'
../boost_1_33_1/boost/serialization/export.hpp:132: instantiated from
`boost::archive::detail::export_generator<T, ASeq>::export_generator()
[with T = LCTextPanel, ASeq =
boost::mpl::list2<boost::archive::xml_oarchive,
boost::archive::xml_iarchive>]'
../boost_1_33_1/boost/serialization/export.hpp:139: instantiated from
`const boost::archive::detail::export_generator<LCTextPanel,
boost::mpl::list2<boost::archive::xml_oarchive,
boost::archive::xml_iarchive> >
boost::archive::detail::export_generator<LCTextPanel,
boost::mpl::list2<boost::archive::xml_oarchive,
boost::archive::xml_iarchive> >::instance'
../boost_1_33_1/boost/serialization/export.hpp:177: instantiated from
`static const boost::archive::detail::export_generator<T, ASeq>*
boost::archive::detail::export_instance<T, ASeq>::not_abstract::invoke()
[with T = LCTextPanel, ASeq =
boost::mpl::list2<boost::archive::xml_oarchive,
boost::archive::xml_iarchive>]'
../boost_1_33_1/boost/serialization/export.hpp:191: instantiated from
`std::pair<const boost::archive::detail::export_generator<T, ASeq>*,
const boost::archive::detail::guid_initializer<T>*>
boost::archive::detail::export_instance_invoke() [with T = LCTextPanel,
ASeq = boost::mpl::list2<boost::archive::xml_oarchive,
boost::archive::xml_iarchive>]'
../boost_1_33_1/boost/serialization/export.hpp:211: instantiated from
`static std::pair<const boost::archive::detail::export_generator<T,
ASeq>*, const boost::archive::detail::guid_initializer<T>*>
boost::archive::detail::export_archives<T,
ASeq>::non_empty_archive_list::invoke() [with T = LCTextPanel, ASeq =
boost::mpl::list2<boost::archive::xml_oarchive,
boost::archive::xml_iarchive>]'
../boost_1_33_1/boost/serialization/export.hpp:225: instantiated from
`std::pair<const boost::archive::detail::export_generator<T, ASeq>*,
const boost::archive::detail::guid_initializer<T>*>
boost::archive::detail::export_archives_invoke(T&, ASeq&) [with T =
LCTextPanel, ASeq = boost::mpl::list2<boost::archive::xml_oarchive,
boost::archive::xml_iarchive>]'
include/TextPanel.hpp:124: instantiated from here
../boost_1_33_1/boost/archive/basic_xml_oarchive.hpp:86: error:
incomplete type `boost::STATIC_ASSERTION_FAILURE< false>' used in nested
name specifier
../boost_1_33_1/boost/archive/basic_xml_oarchive.hpp:86: error: size of
array has non-integral type `<type error>'
../boost_1_33_1/boost/archive/basic_xml_iarchive.hpp: In member function
`void boost::archive::basic_xml_iarchive<Archive>::load_override(T&,
int) [with T = LCPanel, Archive = boost::archive::xml_iarchive]':
../boost_1_33_1/boost/archive/xml_iarchive.hpp:74: instantiated from
`void boost::archive::xml_iarchive_impl<Archive>::load_override(T&, int)
[with T = LCPanel, Archive = boost::archive::xml_iarchive]'
../boost_1_33_1/boost/archive/detail/interface_iarchive.hpp:76:
instantiated from `Archive&
boost::archive::detail::interface_iarchive<Archive>::operator>>(T&)
[with T = LCPanel, Archive = boost::archive::xml_iarchive]'
../boost_1_33_1/boost/archive/detail/interface_iarchive.hpp:83:
instantiated from `Archive&
boost::archive::detail::interface_iarchive<Archive>::operator&(T&) [with
T = LCPanel, Archive = boost::archive::xml_iarchive]'
include/TextPanel.hpp:115: instantiated from `void
LCTextPanel::serialize(Archive&, unsigned int) [with Archive =
boost::archive::xml_iarchive]'
../boost_1_33_1/boost/serialization/access.hpp:109: instantiated from
`static void boost::serialization::access::serialize(Archive&, T&,
unsigned int) [with Archive = boost::archive::xml_iarchive, T =
LCTextPanel]'
../boost_1_33_1/boost/serialization/serialization.hpp:81: instantiated
from `void boost::serialization::serialize(Archive&, T&, unsigned int)
[with Archive = boost::archive::xml_iarchive, T = LCTextPanel]'
../boost_1_33_1/boost/serialization/serialization.hpp:140:
instantiated from `void boost::serialization::serialize_adl(Archive&,
T&, unsigned int) [with Archive = boost::archive::xml_iarchive, T =
LCTextPanel]'
../boost_1_33_1/boost/archive/detail/iserializer.hpp:339: instantiated
from `boost::archive::detail::pointer_iserializer<T,
Archive>::pointer_iserializer() [with T = LCTextPanel, Archive =
boost::archive::xml_iarchive]'
../boost_1_33_1/boost/archive/detail/iserializer.hpp:211: instantiated
from `const boost::archive::detail::pointer_iserializer<LCTextPanel,
boost::archive::xml_iarchive>
boost::archive::detail::pointer_iserializer<LCTextPanel,
boost::archive::xml_iarchive>::instance'
../boost_1_33_1/boost/archive/detail/iserializer.hpp:203: instantiated
from `static const boost::archive::detail::pointer_iserializer<T,
Archive>& boost::archive::detail::pointer_iserializer<T,
Archive>::instantiate() [with T = LCTextPanel, Archive =
boost::archive::xml_iarchive]'
../boost_1_33_1/boost/archive/detail/iserializer.hpp:546: instantiated
from `const boost::archive::detail::basic_pointer_iserializer&
boost::archive::detail::instantiate_pointer_iserializer(Archive*, T*)
[with Archive = boost::archive::xml_iarchive, T = LCTextPanel]'
../boost_1_33_1/boost/serialization/export.hpp:75: instantiated from
`static void boost::archive::detail::export_impl::archive<Archive,
T>::i::invoke() [with Archive = boost::archive::xml_iarchive, T =
LCTextPanel]'
../boost_1_33_1/boost/serialization/export.hpp:105: instantiated from
`static void boost::archive::detail::export_impl::archive<Archive,
T>::instantiate() [with Archive = boost::archive::xml_iarchive, T =
LCTextPanel]'
../boost_1_33_1/boost/serialization/export.hpp:116: instantiated from
`static void boost::archive::detail::export_impl::for_each_archive<ASeq,
T>::instantiate() [with ASeq =
boost::mpl::list1<boost::archive::xml_iarchive>, T = LCTextPanel]'
../boost_1_33_1/boost/serialization/export.hpp:122: instantiated from
`static void boost::archive::detail::export_impl::for_each_archive<ASeq,
T>::instantiate() [with ASeq =
boost::mpl::list2<boost::archive::xml_oarchive,
boost::archive::xml_iarchive>, T = LCTextPanel]'
../boost_1_33_1/boost/serialization/export.hpp:132: instantiated from
`boost::archive::detail::export_generator<T, ASeq>::export_generator()
[with T = LCTextPanel, ASeq =
boost::mpl::list2<boost::archive::xml_oarchive,
boost::archive::xml_iarchive>]'
../boost_1_33_1/boost/serialization/export.hpp:139: instantiated from
`const boost::archive::detail::export_generator<LCTextPanel,
boost::mpl::list2<boost::archive::xml_oarchive,
boost::archive::xml_iarchive> >
boost::archive::detail::export_generator<LCTextPanel,
boost::mpl::list2<boost::archive::xml_oarchive,
boost::archive::xml_iarchive> >::instance'
../boost_1_33_1/boost/serialization/export.hpp:177: instantiated from
`static const boost::archive::detail::export_generator<T, ASeq>*
boost::archive::detail::export_instance<T, ASeq>::not_abstract::invoke()
[with T = LCTextPanel, ASeq =
boost::mpl::list2<boost::archive::xml_oarchive,
boost::archive::xml_iarchive>]'
../boost_1_33_1/boost/serialization/export.hpp:191: instantiated from
`std::pair<const boost::archive::detail::export_generator<T, ASeq>*,
const boost::archive::detail::guid_initializer<T>*>
boost::archive::detail::export_instance_invoke() [with T = LCTextPanel,
ASeq = boost::mpl::list2<boost::archive::xml_oarchive,
boost::archive::xml_iarchive>]'
../boost_1_33_1/boost/serialization/export.hpp:211: instantiated from
`static std::pair<const boost::archive::detail::export_generator<T,
ASeq>*, const boost::archive::detail::guid_initializer<T>*>
boost::archive::detail::export_archives<T,
ASeq>::non_empty_archive_list::invoke() [with T = LCTextPanel, ASeq =
boost::mpl::list2<boost::archive::xml_oarchive,
boost::archive::xml_iarchive>]'
../boost_1_33_1/boost/serialization/export.hpp:225: instantiated from
`std::pair<const boost::archive::detail::export_generator<T, ASeq>*,
const boost::archive::detail::guid_initializer<T>*>
boost::archive::detail::export_archives_invoke(T&, ASeq&) [with T =
LCTextPanel, ASeq = boost::mpl::list2<boost::archive::xml_oarchive,
boost::archive::xml_iarchive>]'
include/TextPanel.hpp:124: instantiated from here
../boost_1_33_1/boost/archive/basic_xml_iarchive.hpp:66: error:
incomplete type `boost::STATIC_ASSERTION_FAILURE< false>' used in nested
name specifier
../boost_1_33_1/boost/archive/basic_xml_iarchive.hpp:66: error: size of
array has non-integral type `<type error>'
This message (including any attachments) contains confidential
and/or proprietary information intended only for the addressee.
Any unauthorized disclosure, copying, distribution or reliance on
the contents of this information is strictly prohibited and may
constitute a violation of law. If you are not the intended
recipient, please notify the sender immediately by responding to
this e-mail, and delete the message from your system. If you
have any questions about this e-mail please notify the sender
immediately.