Brian Silverman | 8867871 | 2018-08-04 23:56:48 -0700 | [diff] [blame^] | 1 | <!doctype HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> |
| 2 | <html> |
| 3 | <!-- |
| 4 | (C) Copyright 2002-4 Robert Ramey - http://www.rrsd.com . |
| 5 | Use, modification and distribution is subject to the Boost Software |
| 6 | License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at |
| 7 | http://www.boost.org/LICENSE_1_0.txt) |
| 8 | --> |
| 9 | <head> |
| 10 | <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> |
| 11 | <link rel="stylesheet" type="text/css" href="../../../boost.css"> |
| 12 | <link rel="stylesheet" type="text/css" href="style.css"> |
| 13 | <title>Serialization - Release Notes</title> |
| 14 | </head> |
| 15 | <body link="#0000ff" vlink="#800080"> |
| 16 | <table border="0" cellpadding="7" cellspacing="0" width="100%" summary="header"> |
| 17 | <tr> |
| 18 | <td valign="top" width="300"> |
| 19 | <h3> |
| 20 | <a href="../../../index.htm"><img height="86" width="277" alt="C++ Boost" src="../../../boost.png" border="0"></a></h3> |
| 21 | </td> |
| 22 | <td valign="top"> |
| 23 | <h1 align="center"> |
| 24 | Serialization</h1> |
| 25 | <h2 align="center"> |
| 26 | Release Notes</h2> |
| 27 | </td> |
| 28 | </tr> |
| 29 | </table> |
| 30 | <hr> |
| 31 | <dl class="index"> |
| 32 | <dt><a href="#differences_1_59">Differences from version 1.58</a></dt> |
| 33 | <dt><a href="#differences_1_58">Differences from version 1.48</a></dt> |
| 34 | <dt><a href="#differences_1_45">Differences from version 1.45</a></dt> |
| 35 | <dt><a href="#differences_1_43">Differences from version 1.43</a></dt> |
| 36 | <dt><a href="#differences_1_42">Differences from version 1.42</a></dt> |
| 37 | <dt><a href="#differences_1_41">Differences from version 1.41</a></dt> |
| 38 | <dt><a href="#differences_1_40">Differences from version 1.40</a></dt> |
| 39 | <dt><a href="#differences_1_39">Differences from version 1.39</a></dt> |
| 40 | <dt><a href="#differences_1_37">Differences from version 1.37</a></dt> |
| 41 | <dt><a href="#differences_1_35">Differences from version 1.35</a></dt> |
| 42 | <dt><a href="#differences_1_34">Differences from version 1.34</a></dt> |
| 43 | <dt><a href="#differences_1_33">Differences from version 1.33</a></dt> |
| 44 | <dt><a href="#differences_1_32">Differences from version 1.32</a></dt> |
| 45 | <dt><a href="#todo">Pending Issues</a></dt> |
| 46 | </dl> |
| 47 | As of this writing, there are no known bugs. However, due to compiler/library |
| 48 | quirks and or bugs, some tests fail with some combinations of compilers and |
| 49 | libraries. |
| 50 | <h2><a name="differences_1_59"></a>Differences from Boost 1.58</h2> |
| 51 | <ul> |
| 52 | <li>Eliminated support for Borland compilers and Microsoft compilers prior to version |
| 53 | 7.1. |
| 54 | <li>Eliminated support for compilers which do not support Partial Function Template |
| 55 | Ordering (pfto). |
| 56 | <li>Added support for "visibility hidden" for GCC compilers. Shared libraries |
| 57 | will only expose symbols actually needed rather than all sympols in the library. This |
| 58 | should result in smaller shared libraries which are faster to load. |
| 59 | </ul> |
| 60 | <h2><a name="differences_1_58"></a>Differences from Boost 1.48</h2> |
| 61 | <ul> |
| 62 | <li>Added support for C++11 types such as std::shared_ptr, std::array, and others. |
| 63 | <li>Implemented the concept of a "Helper" which can be used to implement serialization of types which are otherwise not serializable." |
| 64 | <li>Made library compatible with C++11, Compatibility with C++03 has been maintained. |
| 65 | </ul> |
| 66 | <h2><a name="differences_1_45"></a>Differences from Boost 1.45</h2> |
| 67 | Since the release of version 1.42, it has been discovered that binary |
| 68 | archives created by versions 1.42-1.44 cannot always be read by the |
| 69 | recent binary archive code. Work has proceeded in detecting the source |
| 70 | of these anomolies and those which have been reported with test cases |
| 71 | have been fixed. As of this writing, it is not known whether all |
| 72 | binary archives created with these versions can be loaded. |
| 73 | <h2><a name="differences_1_43"></a>Differences from Boost 1.43</h2> |
| 74 | <ul> |
| 75 | <li>fixed bug in the serialization of virtual base classes. Due |
| 76 | to heroic efforts by Takatoshi Kondo. |
| 77 | <li>Native binary archives created under versions 1.42 and 1.43 |
| 78 | suffer from a serious problem. It's likely they won't be readable |
| 79 | by this latest version. This due to the fact that 1.42 made some |
| 80 | changes in the binary format of some types. Normally this could |
| 81 | be addressed by detecting the library version number written into |
| 82 | the archive header. Unfortunately, this library version number |
| 83 | was not incremented at 1.42 as it should have been. So now we have |
| 84 | two different binary archive versions with the same library version |
| 85 | number. |
| 86 | <p> |
| 87 | This has been addressed by including a small utility in the example |
| 88 | directory named fix_six.cpp. This should be run with the command line<br> |
| 89 | <code><pre> |
| 90 | fix_six <file name> |
| 91 | </pre></code> |
| 92 | This will assign 7 to the library version number of the archive. This |
| 93 | fix will need to ba applied to native binary archives created with |
| 94 | boost versions 1.42 and 1.43. |
| 95 | </ul> |
| 96 | <h2><a name="differences_1_42"></a>Differences from Boost 1.42</h2> |
| 97 | <ul> |
| 98 | <li>fixed failure of shared_ptr serialization when serializing pointers |
| 99 | created from enable_shared_from_this. |
| 100 | <li>added example for a simple archive which can be used as a debug log. |
| 101 | This example illustrates the implemenation of the archive concept to aid |
| 102 | understanding required to create one's own archive classes. The resulting |
| 103 | archive is useful for debugging in that it only 160 lines of code and is |
| 104 | header only - that is, it doesn't required linking to the serialization library. |
| 105 | <li>replaced example used to show how to derive from an existing archive. |
| 106 | This example creates an XML archive class which doesn't include serialization |
| 107 | traits such as class_id, class_version, etc. It might be useful for exporting |
| 108 | one's class information to osme XML processor and/or debugging programs. |
| 109 | <li>compile time warnings have been implemented to detect practices which |
| 110 | though correct, will result in operation or side effects different than |
| 111 | a user probably intends. |
| 112 | <li>Some memory leaks associated with void_cast have been fixed. |
| 113 | </ul> |
| 114 | <h2><a name="differences_1_41"></a>Differences from Boost 1.41</h2> |
| 115 | <ul> |
| 116 | <li>adjustments have been made to minimize compile time warnings. |
| 117 | <li>compile time warnings have been implemented to detect practices which |
| 118 | though correct, will result in operation or side effects different than |
| 119 | a user probably intends. |
| 120 | <li>Some memory leaks associated with void_cast have been fixed. |
| 121 | </ul> |
| 122 | <h2><a name="differences_1_40"></a>Differences from Boost 1.40</h2> |
| 123 | This library has been tested against Boost version 1.39 and 1.40. |
| 124 | <p> |
| 125 | Changes have been made to archive classes included with the library. Users who |
| 126 | have used these a guide to making their own archive classes will find that |
| 127 | these will likely no longer compile. This can be remedied by making the |
| 128 | following changes in the code which instantiates these archive classes. |
| 129 | </p> |
| 130 | Old Code:<br> |
| 131 | <code><pre> |
| 132 | ... |
| 133 | #include <boost/archive/impl/archive_pointer_iserializer.ipp> |
| 134 | ... |
| 135 | template class detail::archive_pointer_iserializer<naked_text_iarchive> ; |
| 136 | ... |
| 137 | template class detail::archive_pointer_iserializer<text_iarchive> ; |
| 138 | </pre></code>should be replaced with this new code: <code><pre> |
| 139 | #include <boost/archive/impl/archive_serializer_map.ipp> |
| 140 | ... |
| 141 | template class detail::archive_serializer_map<naked_text_iarchive> ; |
| 142 | ... |
| 143 | template class detail::archive_serializer_map<text_iarchive> ; |
| 144 | </pre></code> |
| 145 | <!-- |
| 146 | <p> |
| 147 | The serialization library uses the boost spirit package to load XML archives. |
| 148 | We have found that all tests pass using spirit 1.6x. Spirit 1.8 and higher does not work with |
| 149 | older compilers - specifically MSVC 6, Borland and GCC < 3.0. |
| 150 | If you are using one of these compilers, you may download a version |
| 151 | of spirit 1.6 <a href="http://spirit.sourceforge.net/index.php?doc=download/index.html">here</a>. |
| 152 | To use this downloaded version rather than the one included with boost, |
| 153 | set an environmental variable SPIRIT_ROOT to be equal to the root |
| 154 | directory where the downloaded copy of spirit has been placed. E. G. |
| 155 | <pre><code> |
| 156 | set SPIRIT_ROOT=c:/spirit16 |
| 157 | </code></pre> |
| 158 | If you're not using bjam and the Jamfile to build the library, be sure that |
| 159 | the directory which contains the version of spirit you plan to use is placed |
| 160 | at the front of the list of include paths. |
| 161 | --> |
| 162 | <h2><a name="differences_1_39"></a>Differences from Boost 1.39</h2> |
| 163 | <ul> |
| 164 | <li> |
| 165 | It is now possible to serialize an object through a pointer to a class which |
| 166 | implements its own <code style="white-space: normal">new/delete</code> |
| 167 | operators. This functionaly is not available on some compilers. |
| 168 | <li> |
| 169 | serialization of polymorphic objects has been sped up considerably. |
| 170 | </ul> |
| 171 | As of this writing, all bug reports filed as TRAK tickets have been addressed. |
| 172 | There are some TRAK tickets pending which would best be described as feature |
| 173 | requests. See <a href="#todo">Pending Issues</a>. |
| 174 | <h2><a name="differences_1_37"></a>Differences from Boost 1.37</h2> |
| 175 | There are no new features in this version. As of this writing, all bug reports |
| 176 | filed as TRAK tickets have been addressed. There are some TRAK tickets pending |
| 177 | which would best be described as feature requests. See <a href="#todo">Pending |
| 178 | Issues</a>. |
| 179 | <h2><a name="differences_1_36"></a>Differences from Boost 1.36</h2> |
| 180 | There are no new features in this version. As of this writing, all bug reports |
| 181 | filed as TRAK tickets have been addressed. |
| 182 | <h2><a name="differences_1_35"></a>Differences from Boost 1.35</h2> |
| 183 | <ul> |
| 184 | <li> |
| 185 | The library is now thread safe. That is, multiple archives can be open in |
| 186 | different threads. This has been implmented with a lock-free algorithm to avoid |
| 187 | any performance bottlenecks. |
| 188 | <li> |
| 189 | Serialization of types defined in shared libraries is now supported. shared |
| 190 | libraries (DLLS) can be loaded/unloaded dynamically at runtime. This includes |
| 191 | the serialization of instances of abstract base classes so that a program can |
| 192 | be written so as to be compatible with as yet undefined and un-implemented |
| 193 | code. |
| 194 | <li> |
| 195 | The extended type info system has been enhanced to in order to implement the |
| 196 | above. It is now a general purpose system for creating and casting of types |
| 197 | about which is only known a string ID and an abstract base class. |
| 198 | <li> |
| 199 | All bug reports filed as TRAK tickets have been addressed. |
| 200 | <li> |
| 201 | As of this writing, the library will fail build on older compilers such as MSVC |
| 202 | before version 7.1 and older versions of Borland compilers. This might or might |
| 203 | not change in the future. |
| 204 | </ul> |
| 205 | <h2><a name="differences_1_34"></a>Differences from Boost 1.34</h2> |
| 206 | <ul> |
| 207 | <li> |
| 208 | Enhanced support for fast serialization for native binary archives. By Mattias |
| 209 | Troyer. |
| 210 | <li> |
| 211 | Improved implementation of "export" functionality. Removes header ordering |
| 212 | requirement and eliminates the maintenance of a pre-determined list of "known |
| 213 | archives" By David Abrahams. |
| 214 | <li> |
| 215 | Improved support for STLPort. |
| 216 | </ul> |
| 217 | <h2><a name="differences_1_33"></a>Differences from Boost 1.33</h2> |
| 218 | <ul> |
| 219 | <li> |
| 220 | Native Binary archives use the <code style="white-space: normal">std::streambuf</code> |
| 221 | interface. This should result in noticeably faster execution in many cases. |
| 222 | </ul> |
| 223 | <h2><a name="differences_1_32"></a>Differences from Boost 1.32</h2> |
| 224 | <ul> |
| 225 | <li> |
| 226 | Dynamic Linking Library (DLLs and shared libraries) for platforms which support |
| 227 | them. See <a href="../../../more/getting_started/windows.html#auto-linking">Automatic |
| 228 | Linking on Windows</a>. |
| 229 | <li> |
| 230 | Implementation of auto-link for compilers which can support this. |
| 231 | <li> |
| 232 | Better support for <em>Argument Dependent Lookup</em> |
| 233 | and two-phase lookup. This results in simpler rules regarding the placing of |
| 234 | serialization specializations namespaces. |
| 235 | <li> |
| 236 | Enhanced documentation to help explain usage of the above. |
| 237 | <li> |
| 238 | Adjustments to improve support for less conformant compilers. |
| 239 | <li> |
| 240 | Improved <code>const</code> correctness for save/load operators. Note that this |
| 241 | may produce compile time errors in code which compiled without problem in |
| 242 | earlier boost releases. In most cases the fix is trivial. In other cases, code |
| 243 | should be scrutinized to be sure that it doesn't use the serialization system |
| 244 | in a way which may introduce subtle bugs in to the program. A fuller |
| 245 | explanation of this issue can be found <a target="detail" href="traits.html#tracking"> |
| 246 | here</a>. |
| 247 | <li> |
| 248 | A new implementation of serialization for <code style="white-space: normal">shared_ptr<T></code>. |
| 249 | This is compatible with public interface of <code style="white-space: normal">shared_ptr<T></code> |
| 250 | so it should be more robust and not have to change in the future. The |
| 251 | implementation optionally includes code to load <code style="white-space: normal">shared_ptr<T></code> |
| 252 | stored in archives created with boost 1.32. This code is stored in 'he header: <code style="white-space: normal"> |
| 253 | boost/serialization/shared_ptr_132.hpp</code>. If your application needs to |
| 254 | load archives created with boost 1.32 libraries, include the above header |
| 255 | before each inclusion of <code style="white-space: normal">boost/serialization/shared_ptr.hpp</code>. |
| 256 | <li> |
| 257 | More compilers tested and supported. |
| 258 | <li> |
| 259 | Miscellaneous bug fixes. |
| 260 | </ul> |
| 261 | <h2><a name="todo"></a>Pending issues</h2> |
| 262 | <ul> |
| 263 | <li> |
| 264 | Rvalues cannot be serialized. It would be possible to implement this for |
| 265 | untracked types, but this has not been done. |
| 266 | <li> |
| 267 | Pointers to pointers cannot currently be serialized |
| 268 | <li> |
| 269 | It's possible that <code style="white-space: normal">std::string</code> and <code style="white-space: normal"> |
| 270 | std::wstring</code> |
| 271 | contain characters such as '\0' and -1 (EOF) which cannot be rendered in text |
| 272 | and XML archives without an escape mechanism. Currently there is no such escape |
| 273 | mechanism implemented. |
| 274 | <li> |
| 275 | A subtle error in the implementation of serializaton of <code style="white-space: normal"> |
| 276 | std::map</code> is fixed in this version. Unfortunately, the fix breaks |
| 277 | serialization of <code style="white-space: normal">std::map</code> |
| 278 | for those compilers which do not support partial template specialization. Also, |
| 279 | types which contain pointers or tracked types might not work correctly. |
| 280 | <li> |
| 281 | Serialization of virtual base classes relies upon RTTI. It will fail when used on |
| 282 | systems which don't have RTTI enabled. |
| 283 | </ul> |
| 284 | <p> |
| 285 | Aside from the above, there are a number of issues related to specific |
| 286 | platforms. These are listed in <a href="implementation.html#othercompilerissues">Specific |
| 287 | Compiler/Library Issues</a>. |
| 288 | <hr> |
| 289 | <p> |
| 290 | <i>© Copyright <a href="http://www.rrsd.com">Robert Ramey</a> 2002-2009. |
| 291 | Distributed under the Boost Software License, Version 1.0. (See accompanying |
| 292 | file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) </i> |
| 293 | </p> |
| 294 | </body> |
| 295 | </html> |