Re: [Boost-bugs] [Boost C++ Libraries] #3315: Compile-time instantiation causing failure to deserialize std::vector<char>.

Subject: Re: [Boost-bugs] [Boost C++ Libraries] #3315: Compile-time instantiation causing failure to deserialize std::vector<char>.
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2009-08-04 22:14:14


#3315: Compile-time instantiation causing failure to deserialize
std::vector<char>.
----------------------------------------------------+-----------------------
  Reporter: Jarl Lindrud <jarl.lindrud@…> | Owner: ramey
      Type: Bugs | Status: closed
 Milestone: Boost 1.40.0 | Component: serialization
   Version: Boost 1.39.0 | Severity: Problem
Resolution: wontfix | Keywords:
----------------------------------------------------+-----------------------
Changes (by ramey):

  * status: new => closed
  * resolution: => wontfix

Comment:

 I've looked into this. When the serialization traits of a type are

 tracking = track_selectively
 implemenation_level <= object_serializable

 No information regarding the type is included in the archive. This is
 decision based on efficiency considerations. The decision to track is
 dependent solely upon the code in the program. Thus the side effect of
 including code even it is not called. Note that default implementation of
 serialization of collections of primitive types such as vector<char> are
 setup with these traits.

 So this behavior is by design. Whether or not this is a good design
 decision would be a different discussion. I wouldn't change it now since
 it would likely break a lot of archives "out there"

 I did include a BOOST_STATIC_WARNING if one attempts to save a pointer to
 such a type. Doing this would be unusual and could result and archive
 which might be unreadable.

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/3315#comment:1>
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:00 UTC