Subject: Re: [Boost-bugs] [Boost C++ Libraries] #1290: Serialization export.hpp (or type_info_implementation.hpp) is NOT self-contained and causes compile error
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2007-11-12 15:58:59
#1290: Serialization export.hpp (or type_info_implementation.hpp) is NOT self-
contained and causes compile error
------------------------------------+---------------------------------------
Reporter: huangsean_at_[hidden] | Owner: ramey
Type: Bugs | Status: new
Milestone: To Be Determined | Component: serialization
Version: Boost 1.34.1 | Severity: Showstopper
Resolution: | Keywords:
------------------------------------+---------------------------------------
Comment (by Julian <julian.magnone+boost_at_[hidden]>):
We are having the same problem.
We used the following macro instead and it worked fine but hasn't sense
for us, because we are using gcc for compile the source code, and this
Macro is for CodeWarrior.
export.hpp[[BR]]
166 // CodeWarrior fails to construct static members of class
templates[[BR]]
167 // when they are instantiated from within templates, so on
that[[BR]]
168 // compiler we ask users to specifically register base/derived
class[[BR]]
169 // relationships for exported classes. On all other compilers,
use of[[BR]]
170 // this macro is entirely optional.[[BR]]
'''171 # define BOOST_SERIALIZATION_MWERKS_BASE_AND_DERIVED(Base,Derived)
\'''[[BR]]
172 namespace
\[[BR]]
173 {
\[[BR]]
174 int BOOST_PP_CAT(boost_serialization_mwerks_init_, __LINE__) =
\[[BR]]
175
(::boost::archive::detail::instantiate_ptr_serialization((Derived*)0,0),
3); \[[BR]]
176 int BOOST_PP_CAT(boost_serialization_mwerks_init2_, __LINE__) =
( \[[BR]]
177
::boost::serialization::void_cast_register((Derived*)0,(Base*)0)
\[[BR]]
178 , 3);
\[[BR]]
179 }[[BR]]
180 [[BR]]
--
Ticket URL: <http://svn.boost.org/trac/boost/ticket/1290#comment:2>
Boost C++ Libraries <http://www.boost.org/>
Boost provides free peer-reviewed portable C++ source libraries.
This archive was generated by hypermail 2.1.7 : 2017-02-16 18:49:56 UTC