Subject: Re: [Boost-bugs] [Boost C++ Libraries] #9612: Memory Access Violation when recursively serializing classes
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2014-02-02 21:37:20
#9612: Memory Access Violation when recursively serializing classes
------------------------------------------+---------------------------
Reporter: Chris Rusby <chris.rusby@â¦> | Owner: ramey
Type: Bugs | Status: closed
Milestone: To Be Determined | Component: serialization
Version: Boost 1.55.0 | Severity: Problem
Resolution: invalid | Keywords:
------------------------------------------+---------------------------
Comment (by brandon.kohn):
I've looked into this a bit more and I think there is a way to support
this case for compilers which support extern templates. That includes msvc
back to 8.0.
The trick is to combine the dllexport/import with the extern for the
explicit instantiations of the singleton's for the i/oserialzer instances.
This requires changes to singleton.hpp (moved the exports to the class
level.) Was there a particular reason the exports were put on the members?
I put together a patch. Check it out Chris.
Note: There is a warning by the vc12 compiler c4910 :
http://msdn.microsoft.com/en-us/library/bb531392%28v=vs.90%29.aspx
I agree with the comment on that page that this shouldn't be a warning.
Export and extern are not mutually exclusive and should be able to modify
the same thing. In spite of the warning, the compiled code does the right
thing in all the versions I tested. (vc11, vc12).
-- Ticket URL: <https://svn.boost.org/trac/boost/ticket/9612#comment:5> 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:50:15 UTC