diff options
Diffstat (limited to '')
301 files changed, 42081 insertions, 0 deletions
diff --git a/src/boost/libs/serialization/CMake/CMakeLists.txt b/src/boost/libs/serialization/CMake/CMakeLists.txt new file mode 100644 index 00000000..00868f85 --- /dev/null +++ b/src/boost/libs/serialization/CMake/CMakeLists.txt @@ -0,0 +1,464 @@ +# CMake build control file for Serialization Library tests + +cmake_minimum_required(VERSION 3.0) + +if (POLICY CMP0054) + cmake_policy (SET CMP0054 NEW) +endif (POLICY CMP0054) + +if (POLICY CMP0063) + cmake_policy (SET CMP0063 NEW) +endif (POLICY CMP0063) + +if(Boost_USE_STATIC_LIBS) + project("Serialization-Static") +else() + project("Serialization-Shared") +endif() + +# +# Compiler settings +# + +message(STATUS "compiler is ${CMAKE_CXX_COMPILER_ID}" ) +add_definitions(${Boost_LIB_DIAGNOSTIC_DEFINITIONS}) + +if( CMAKE_CXX_COMPILER_ID STREQUAL "GNU" ) + add_definitions( -ftemplate-depth=300 ) + # we use gcc to test for C++03 compatibility + add_definitions( -std=c++03 ) + message(STATUS "compiler is g++ c++03") + set(COMPILER_SUPPORTS_CXX11 FALSE) +elseif( CMAKE_CXX_COMPILER_ID STREQUAL "MSVC" ) + add_definitions( /wd4996 ) + message(STATUS "compiler is MSVC") + set(COMPILER_SUPPORTS_CXX11 TRUE) +elseif( CMAKE_CXX_COMPILER_ID STREQUAL "AppleClang" ) + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -ftemplate-depth=300") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++03") + #set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11") + set(CMAKE_CXX_FLAGS_DEBUG "-g -O0" ) + set(CMAKE_CXX_FLAGS_RELWITHDEBINFO "-g -O3" ) + set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -stdlib=libc++ -dead_strip") + set(COMPILER_SUPPORTS_CXX11 FALSE) +endif() + +# +# Locate Project Prerequisites +# + +# Boost + +# note: we're assuming that boost has been built with: +# ./b2 —-layout=versioned toolset=clang-darwin link=static,shared variant=debug,release stage + +########################### +# special notes for Xcode. + +# these three should result in CMake setting the variables +# Boost_SERIALIZATION_LIBRARY_DEBUG … to the correct values. + +# But my current version of CMake doesn't automatically set the library names +# to point to the the libraries to be used. The variables are created +# but they are not initialized. So be prepared to set these variables by hand. +# If you want to use the static libraries - point to the boost libraries ending +# in ".a". If you want to use the shared boost libraries - point to the libraries +# ending in ".dylib". + +# But wait - there's more. +# if both lib.a and lib.dylib both exist in the library directory, Xcode will +# automatically chose the *.dylib one - and there's nothing you can do to fix this. +# So my recommendation is +# a) to place the compiled libraries in two different directories +# - e.g. stage/lib-static/*.a and stage/lib-shared/*.dylib +# and set the CMake variable Boost_LIBRARY_DIR to point to one or the other +# b) create two different CMake build directories - build-static and build-shared +# and switch between projects as desired. I like to test both since +# there are things like dead code elimination and visibility which vary +# between the two environments. +# +# caveat - as I write this, I've been unable to get the tests on the shared +# library to function. Problem is that one needs to either put the shared +# libraries in a special known place or set an environmental +# variable which points to the shared library directory. I prefer the latter +# but I've been unable to figure out how to get Xcode to do on a global basis +# and it's not practical to do this for 247 test targets one at a time. + +# c) The targets in the project will by default be built as universal 32/64 binaries +# I have yet to experiment with these yet so I just set the target to 64 bit. + +# end special note for Xcode +############################ + +# +# IDE settings +# + +set(Boost_DEBUG true) +set(Boost_ADDRESS_MODEL 64 CACHE STRING "32/64 bits") +set(Boost_USE_STATIC_LIBS TRUE CACHE BOOL "Use static libraries") +set(Boost_USE_MULTITHREADED ON) +set(Boost_DETAILED_FAILURE_MSG true) + +get_filename_component(BOOST_ROOT "../../.." ABSOLUTE) +string(CONCAT boost_headers ${BOOST_ROOT} "/boost") +if(NOT IS_DIRECTORY ${boost_headers}) + message(FATAL_ERROR "BOOST_ROOT not found") +else() + message(STATUS "BOOST_ROOT is ${BOOST_ROOT}") +endif() + +if(Boost_USE_STATIC_LIBS) + message(STATUS "Link to Boost static libraries") + set(BUILD_SHARED_LIBS NO) + string(CONCAT boost_stage ${BOOST_ROOT} "/stage/Debug/static") +else() + message(STATUS "Link to Boost shared libraries") + set(BUILD_SHARED_LIBS YES) + add_definitions( "-DBOOST_ALL_DYN_LINK=1") + add_definitions( "-DBOOST_ALL_NO_LIB=1") + add_definitions( "-DBOOST_LIB_DIAGNOSTICS=1") + set(CMAKE_CXX_VISIBILITY_PRESET hidden) + set(VISIBILITY_INLINES_HIDDEN YES) + string(CONCAT boost_stage ${BOOST_ROOT} "/stage/Debug/shared") +endif() + +include(CheckIncludeFileCXX) + +message(STATUS "Boost directories found at ${boost_headers}") +message(STATUS "Boost libraries found at ${boost_stage}") +set(CMAKE_LIBRARY_PATH ${boost_stage}) + +# list of archive names for which tests should be generated +#set(archive_list text_archive text_warchive binary_archive xml_archive xml_warchive) +set(archive_list text_archive) + +# list of tests generated by each function call +set(test_list) + +include_directories(BEFORE ${BOOST_ROOT}) + +########################### +# library builds + +add_library(serialization + ../src/archive_exception.cpp + ../src/basic_archive.cpp + ../src/basic_iarchive.cpp + ../src/basic_iserializer.cpp + ../src/basic_oarchive.cpp + ../src/basic_oserializer.cpp + ../src/basic_pointer_iserializer.cpp + ../src/basic_pointer_oserializer.cpp + ../src/basic_serializer_map.cpp + ../src/basic_text_iprimitive.cpp + ../src/basic_text_oprimitive.cpp + ../src/basic_xml_archive.cpp + ../src/binary_iarchive.cpp + ../src/binary_oarchive.cpp + ../src/extended_type_info_no_rtti.cpp + ../src/extended_type_info_typeid.cpp + ../src/extended_type_info.cpp + ../src/polymorphic_iarchive.cpp + ../src/polymorphic_oarchive.cpp + ../src/polymorphic_text_iarchive.cpp + ../src/polymorphic_text_oarchive.cpp + ../src/stl_port.cpp + ../src/text_iarchive.cpp + ../src/text_oarchive.cpp + ../src/void_cast.cpp + ../src/xml_archive_exception.cpp + ../src/xml_iarchive.cpp + ../src/xml_oarchive.cpp + ../src/xml_grammar.cpp + ../src/utf8_codecvt_facet.cpp + ../src/basic_xml_grammar.ipp # doesn't show up in "Source Files" in Xcode"' +) + +add_library(wserialization + ../src/codecvt_null.cpp + ../src/basic_text_wiprimitive.cpp + ../src/basic_text_woprimitive.cpp + ../src/text_wiarchive.cpp + ../src/text_woarchive.cpp + ../src/xml_wiarchive.cpp + ../src/xml_woarchive.cpp + ../src/xml_wgrammar.cpp + ../src/basic_xml_grammar.ipp # doesn't show up in "Source Files" in Xcode"' +) + +set_property(TARGET wserialization PROPERTY LINK_LIBRARIES serialization) + +# end library build +########################### + +add_library(filesystem SHARED IMPORTED GLOBAL ) # or STATIC instead of SHARED +set_target_properties(filesystem PROPERTIES + IMPORTED_LOCATION "${CMAKE_LIBRARY_PATH}/libboost_filesystem-clang-darwin-mt-d-x64-1_69.dylib" +) +get_property(loc TARGET filesystem PROPERTY LOCATION) +message(STATUS "filesystem library located at:${loc}") + +########################### +# test targets + +function( serialization_test test_name) + set(arglist) + foreach(a IN ITEMS ${ARGN} ) + set(arglist ${arglist} ../test/${a}.cpp) + endforeach() + message(STATUS ${test_name}) + add_executable( ${test_name} ../test/${test_name}.cpp ${arglist} ) + target_link_libraries(${test_name} serialization wserialization filesystem) + add_test( ${test_name} ${test_name} ) +endfunction(serialization_test) + +function(archive_test test_name) + set(test_list) + set(arglist) + foreach(a IN ITEMS ${ARGN} ) + set(arglist ${arglist} ../test/${a}.cpp) + endforeach() + foreach( + archive-name + IN ITEMS ${archive_list} + ) + set(amended_test_name ${test_name}_${archive-name}) + add_executable(${amended_test_name} ../test/${test_name}.cpp ${arglist}) + set_property( + TARGET ${amended_test_name} + PROPERTY COMPILE_DEFINITIONS BOOST_ARCHIVE_TEST=${archive-name}.hpp + ) + message(STATUS ${amended_test_name} " " ${arglist} " " ${archive-name}) + target_link_libraries(${amended_test_name} serialization wserialization filesystem) + add_test(${amended_test_name} ${amended_test_name}) + set(test_list ${test_list} ${amended_test_name} PARENT_SCOPE) + endforeach() +endfunction(archive_test) + +function(polymorphic_archive_test test_name) + set(test_list) + set(arglist) + foreach(a IN ITEMS ${ARGN} ) + set(arglist ${arglist} ../test/${a}.cpp) + endforeach() + foreach( + archive-name + IN ITEMS ${archive_list} + ) + set(amended_archive_name polymorphic_${archive-name}) + set(amended_test_name ${test_name}_${amended_archive_name}) + add_executable(${amended_test_name} ../test/${test_name}.cpp ${arglist}) + set_property( + TARGET ${amended_test_name} + PROPERTY COMPILE_DEFINITIONS BOOST_ARCHIVE_TEST=${amended_archive_name}.hpp + ) + message(STATUS ${amended_test_name} " " ${arglist} " " ${amended_archive_name}) + target_link_libraries(${amended_test_name} serialization wserialization filesystem) + add_test(${amended_test_name} ${amended_test_name}) + set(test_list ${test_list} ${amended_test_name} PARENT_SCOPE) + endforeach() +endfunction(polymorphic_archive_test) + +enable_testing() + +message(STATUS dll_a) +add_library(dll_a SHARED ../test/dll_a.cpp) +target_link_libraries(dll_a serialization) +serialization_test(test_dll_simple) +target_link_libraries(test_dll_simple dll_a serialization) + +message(STATUS dll_polymorphic_base) +add_library(dll_polymorphic_base SHARED ../test/dll_polymorphic_base.cpp) +target_link_libraries(dll_polymorphic_base serialization) + +message(STATUS dll_polymorphic_derived2) +add_library(dll_polymorphic_derived2 SHARED ../test/dll_polymorphic_derived2.cpp) +target_link_libraries(dll_polymorphic_derived2 dll_polymorphic_base serialization) + +# compile test_dll_plugin.cpp +# Running the following test requires that the test know the directory +# in which the dll is stored. I don't know how to extract this from bjam +# serialization(test_dll_plugin : : dll_polymorphic_derived2_lib) + +serialization_test(test_private_ctor) +serialization_test(test_reset_object_address A) +serialization_test(test_void_cast) +serialization_test(test_mult_archive_types) +serialization_test(test_iterators) +serialization_test(test_iterators_base64) +serialization_test(test_inclusion) +serialization_test(test_inclusion2) +serialization_test(test_smart_cast) +serialization_test(test_codecvt_null ../src/codecvt_null) +serialization_test(test_strong_typedef) +serialization_test(test_singleton) +serialization_test(test_singleton_inherited) +serialization_test(test_singleton_plain) + +archive_test(test_native_array A) +archive_test(test_boost_array A) +if(COMPILER_SUPPORTS_CXX11) + archive_test(test_array A) +endif() +archive_test(test_binary) +archive_test(test_bitset) +archive_test(test_class_info_save) +archive_test(test_class_info_load) +archive_test(test_complex) +archive_test(test_contained_class A) +archive_test(test_cyclic_ptrs A) +archive_test(test_delete_pointer) +archive_test(test_deque A) +archive_test(test_derived) +archive_test(test_derived_class A) +archive_test(test_diamond) +archive_test(test_diamond_complex) +archive_test(test_forward_list A) +archive_test(test_forward_list_ptrs A) +archive_test(test_helper_support) +archive_test(test_interrupts) +archive_test(test_list A) +archive_test(test_list_ptrs A) +archive_test(test_map A) +archive_test(test_map_boost_unordered A) +archive_test(test_mi) +archive_test(test_multiple_ptrs A) +archive_test(test_multiple_inheritance) +archive_test(test_new_operator A) +archive_test(test_non_intrusive) +archive_test(test_non_default_ctor) +archive_test(test_non_default_ctor2) +archive_test(test_null_ptr) +archive_test(test_nvp A) +archive_test(test_object) +archive_test(test_optional) +archive_test(test_primitive) +archive_test(test_priority_queue A) +archive_test(test_private_base) +archive_test(test_private_base2) +archive_test(test_queue A) +archive_test(test_recursion A) +archive_test(test_registered) +archive_test(test_shared_ptr) +archive_test(test_shared_ptr_multi_base) +archive_test(test_shared_ptr_132) +archive_test(test_simple_class A) +archive_test(test_simple_class_ptr A) +CHECK_INCLUDE_FILE_CXX(slist SLIST_FOUND) +if(SLIST_FOUND) + message(STATUS "slist header found") + archive_test(test_slist A) + archive_test(test_slist_ptr A) +else() + message(STATUS "slist header NOT found") +endif() +archive_test(test_stack A) +archive_test(test_split) +archive_test(test_tracking) +archive_test(test_unregistered) +archive_test(test_unique_ptr) +archive_test(test_valarray) +archive_test(test_variant A) +archive_test(test_vector A) +archive_test(test_set A) +archive_test(test_set_boost_unordered A) +if(COMPILER_SUPPORTS_CXX11) + archive_test(test_set_unordered A) +else() + CHECK_INCLUDE_FILE_CXX(hash_set HASH_SET_FOUND) + if(HASH_SET_FOUND) + archive_test(test_set_hashed A) + endif() +endif() +if(COMPILER_SUPPORTS_CXX11) + archive_test(test_map_unordered A) +else() + CHECK_INCLUDE_FILE_CXX(hash_map HASH_MAP_FOUND) + if(HASH_MAP_FOUND) + archive_test(test_map_hashed A) + endif() +endif() + +polymorphic_archive_test(test_dll_exported polymorphic_derived1) +foreach(test_name IN ITEMS ${test_list} ) + target_link_libraries(${test_name} dll_polymorphic_derived2 dll_polymorphic_base) + message(STATUS " " target_link_libraries " " dll_polymorphic_derived2 " " dll_polymorphic_base) +endforeach() + +polymorphic_archive_test(test_no_rtti polymorphic_base polymorphic_derived1 polymorphic_derived2) +polymorphic_archive_test(test_exported polymorphic_base polymorphic_derived1 polymorphic_derived2) +polymorphic_archive_test(test_polymorphic test_polymorphic_A A) +polymorphic_archive_test(test_polymorphic2 test_polymorphic2imp) +polymorphic_archive_test(test_p_helper) + +# end test targets +#################### + +#################### +# add headers in IDE + +# for serialization + +file(GLOB x + RELATIVE "${CMAKE_CURRENT_SOURCE_DIR}" + "${CMAKE_CURRENT_SOURCE_DIR}/../include/boost/archive/*.hpp" +) +add_custom_target(archive SOURCES ${x}) +set_property(TARGET archive PROPERTY FOLDER "serialization") + +file(GLOB x + RELATIVE "${CMAKE_CURRENT_SOURCE_DIR}" + "${CMAKE_CURRENT_SOURCE_DIR}/../include/boost/archive/detail/*.hpp" +) +add_custom_target(archive-detail SOURCES ${x}) +set_property(TARGET archive-detail PROPERTY FOLDER "serialization") + +file(GLOB x + RELATIVE "${CMAKE_CURRENT_SOURCE_DIR}" + "${CMAKE_CURRENT_SOURCE_DIR}/../include/boost/archive/impl/*.ipp" +) +add_custom_target(archive-impl SOURCES ${x}) +set_property(TARGET archive-impl PROPERTY FOLDER "serialization") + +file(GLOB x + RELATIVE "${CMAKE_CURRENT_SOURCE_DIR}" + "${CMAKE_CURRENT_SOURCE_DIR}/../include/boost/archive/iterators/*.hpp" +) +add_custom_target(archive-iterators SOURCES ${x}) +set_property(TARGET archive-iterators PROPERTY FOLDER "serialization") + +file(GLOB x + RELATIVE "${CMAKE_CURRENT_SOURCE_DIR}" + "${CMAKE_CURRENT_SOURCE_DIR}/../include/boost/serialization/*.hpp" +) +add_custom_target(serialization-headers SOURCES ${x}) +set_property(TARGET serialization-headers PROPERTY FOLDER "serialization") + +file(GLOB x + RELATIVE "${CMAKE_CURRENT_SOURCE_DIR}" + "${CMAKE_CURRENT_SOURCE_DIR}/../include/boost/serialization/detail/*.hpp" +) +add_custom_target(serialization-detail SOURCES ${x}) +set_property(TARGET serialization-detail PROPERTY FOLDER "serialization") + +# for wserialization + +file(GLOB x + RELATIVE "${CMAKE_CURRENT_SOURCE_DIR}" + "${CMAKE_CURRENT_SOURCE_DIR}/../include/boost/archive/*_w*.hpp" +) +add_custom_target(wserialization_headers SOURCES ${x}) +set_property(TARGET wserialization_headers PROPERTY FOLDER "wserialization") + +# end headers in IDE +#################### + +##################### +# add test project to run misc tests + +add_executable( test_z ../test/test_z.cpp) +target_link_libraries(test_z serialization wserialization ${Boost_LIBRARIES}) + +# end test project +##################### diff --git a/src/boost/libs/serialization/build/Jamfile.v2 b/src/boost/libs/serialization/build/Jamfile.v2 new file mode 100644 index 00000000..1504abcb --- /dev/null +++ b/src/boost/libs/serialization/build/Jamfile.v2 @@ -0,0 +1,139 @@ +# Boost serialization Library Build Jamfile +# (C) Copyright Robert Ramey 2002-2004. +# Use, modification, and distribution are subject to the +# Boost Software License, Version 1.0. (See accompanying file +# LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) +# +# See http://www.boost.org/libs/serialization for the library home page. + +project boost/serialization + : source-location ../src + : requirements + <conditional>@include-spirit +; + +SPIRIT_ROOT = [ modules.peek : SPIRIT_ROOT ] ; +rule include-spirit ( properties * ) +{ + local old-compiler ; + if <toolset>borland in $(properties) + { + if ! <toolset-borland:version>6.1.0 in $(properties) + { + old-compiler = true ; + } + + } + else if <toolset>msvc in $(properties) + { + if <toolset-msvc:version>6.5 in $(properties) + || <toolset-msvc:version>7.0 in $(properties) + { + old-compiler = true ; + } + } + + local result ; + if $(old-compiler) + { + if $(SPIRIT_ROOT) + { + # note - we can't use <include>$(SPIRIT_ROOT) because + # it puts -I$(SPIRIT_ROOT) AFTER the "../../.." in the command line. + # so use these instead + result = <cxxflags>-I$(SPIRIT_ROOT) ; + } + else + { + echo **** spirit 1.6x required to build library with this compiler **** ; + result = <build>no ; + } + } + return $(result) ; +} + +SOURCES = + basic_archive + basic_iarchive + basic_iserializer + basic_oarchive + basic_oserializer + basic_pointer_iserializer + basic_pointer_oserializer + basic_serializer_map + basic_text_iprimitive + basic_text_oprimitive + basic_xml_archive + binary_iarchive + binary_oarchive + extended_type_info + extended_type_info_typeid + extended_type_info_no_rtti + polymorphic_iarchive + polymorphic_oarchive + stl_port + text_iarchive + text_oarchive + polymorphic_text_iarchive + polymorphic_text_oarchive + polymorphic_binary_iarchive + polymorphic_binary_oarchive + polymorphic_xml_iarchive + polymorphic_xml_oarchive + void_cast + archive_exception + xml_grammar + xml_iarchive + xml_oarchive + xml_archive_exception + codecvt_null + utf8_codecvt_facet + ; + +WSOURCES = + basic_text_wiprimitive + basic_text_woprimitive + text_wiarchive + text_woarchive + polymorphic_text_wiarchive + polymorphic_text_woarchive + xml_wgrammar + xml_wiarchive + xml_woarchive + polymorphic_xml_wiarchive + polymorphic_xml_woarchive +; + +lib boost_serialization + : $(SOURCES).cpp + : + <toolset>msvc:<cxxflags>/Gy + <toolset>msvc:<define>_SCL_SECURE_NO_WARNINGS + <toolset>msvc:<define>_CRT_SECURE_NO_WARNINGS + <toolset>clang:<cxxflags>"-fvisibility=hidden -fvisibility-inlines-hidden" + <toolset>gcc:<cxxflags>"-fvisibility=hidden -fvisibility-inlines-hidden" + <toolset>darwin:<cxxflags>"-fvisibility=hidden -fvisibility-inlines-hidden" + <toolset>gcc:<cxxflags>"-ftemplate-depth-255" + <toolset>clang:<cxxflags>"-ftemplate-depth-255" + <toolset>darwin:<cxxflags>"-ftemplate-depth-255" + <link>shared:<define>BOOST_SERIALIZATION_DYN_LINK=1 + ; + +lib boost_wserialization + : $(WSOURCES).cpp boost_serialization + : + <toolset>msvc:<cxxflags>/Gy + <toolset>msvc:<define>_SCL_SECURE_NO_WARNINGS + <toolset>msvc:<define>_CRT_SECURE_NO_WARNINGS + <toolset>clang:<cxxflags>"-fvisibility=hidden -fvisibility-inlines-hidden" + <toolset>gcc:<cxxflags>"-fvisibility=hidden -fvisibility-inlines-hidden" + <toolset>darwin:<cxxflags>"-fvisibility=hidden -fvisibility-inlines-hidden" + <toolset>gcc:<cxxflags>"-ftemplate-depth-255" + <toolset>clang:<cxxflags>"-ftemplate-depth-255" + <toolset>darwin:<cxxflags>"-ftemplate-depth-255" + # note: both serialization and wserialization are conditioned on the this + # switch - don't change it to BOOST_WSERIALIZATION_DYN_LINK + <link>shared:<define>BOOST_SERIALIZATION_DYN_LINK=1 + ; + +boost-install boost_serialization boost_wserialization ; diff --git a/src/boost/libs/serialization/example/Jamfile.v2 b/src/boost/libs/serialization/example/Jamfile.v2 new file mode 100644 index 00000000..cce6ee65 --- /dev/null +++ b/src/boost/libs/serialization/example/Jamfile.v2 @@ -0,0 +1,42 @@ +# Boost serialization Library Build Jamfile +# (C) Copyright Robert Ramey 2002-2004. +# Use, modification, and distribution are subject to the +# Boost Software License, Version 1.0. (See accompanying file +# LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) +# +# See http://www.boost.org/libs/serialization for the library home page. + +project libs/serialization/example + : id serialization_example + : requirements <library>../build//boost_serialization + ; + +import ../util/test : + run-template + run-invoke + run-winvoke + test-bsl-run-no-lib + test-bsl-run + test-bsl-run_archive + test-bsl-run_files + test-bsl-run_polymorphic_archive +; + +test-suite "demo-suite" : + # demos + [ test-bsl-run demo ] + [ test-bsl-run demo_auto_ptr ] + [ test-bsl-run demo_exception ] + [ test-bsl-run demo_fast_archive ] + [ test-bsl-run demo_log : log_archive ] + [ test-bsl-run demo_pimpl : demo_pimpl_A ] + [ test-bsl-run demo_polymorphic : demo_polymorphic_A ] + [ test-bsl-run demo_portable_archive : portable_binary_iarchive portable_binary_oarchive ] + [ test-bsl-run demo_shared_ptr ] + [ test-bsl-run demo_simple_log ] + [ test-bsl-run demo_trivial_archive ] + [ test-bsl-run demo_xml ] + [ test-bsl-run demo_xml_save ] + [ test-bsl-run demo_xml_load : : : <dependency>demo_xml_save ] +; + diff --git a/src/boost/libs/serialization/example/demo.cpp b/src/boost/libs/serialization/example/demo.cpp new file mode 100644 index 00000000..98e987fd --- /dev/null +++ b/src/boost/libs/serialization/example/demo.cpp @@ -0,0 +1,377 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// demo.cpp +// +// (C) Copyright 2002-4 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + + +#include <cstddef> // NULL +#include <iomanip> +#include <iostream> +#include <fstream> +#include <string> + +#include <boost/archive/tmpdir.hpp> + +#include <boost/archive/text_iarchive.hpp> +#include <boost/archive/text_oarchive.hpp> + +#include <boost/serialization/base_object.hpp> +#include <boost/serialization/utility.hpp> +#include <boost/serialization/list.hpp> +#include <boost/serialization/assume_abstract.hpp> + +///////////////////////////////////////////////////////////// +// The intent of this program is to serve as a tutorial for +// users of the serialization package. An attempt has been made +// to illustrate most of the facilities of the package. +// +// The intent is to create an example suffciently complete to +// illustrate the usage and utility of the package while +// including a minimum of other code. +// +// This illustration models the bus system of a small city. +// This includes, multiple bus stops, bus routes and schedules. +// There are different kinds of stops. Bus stops in general will +// will appear on multiple routes. A schedule will include +// muliple trips on the same route. + +///////////////////////////////////////////////////////////// +// gps coordinate +// +// llustrates serialization for a simple type +// +class gps_position +{ + friend std::ostream & operator<<(std::ostream &os, const gps_position &gp); + friend class boost::serialization::access; + int degrees; + int minutes; + float seconds; + template<class Archive> + void serialize(Archive & ar, const unsigned int /* file_version */){ + ar & degrees & minutes & seconds; + } +public: + // every serializable class needs a constructor + gps_position(){}; + gps_position(int _d, int _m, float _s) : + degrees(_d), minutes(_m), seconds(_s) + {} +}; +std::ostream & operator<<(std::ostream &os, const gps_position &gp) +{ + return os << ' ' << gp.degrees << (unsigned char)186 << gp.minutes << '\'' << gp.seconds << '"'; +} + +///////////////////////////////////////////////////////////// +// One bus stop +// +// illustrates serialization of serializable members +// + +class bus_stop +{ + friend class boost::serialization::access; + friend std::ostream & operator<<(std::ostream &os, const bus_stop &gp); + virtual std::string description() const = 0; + gps_position latitude; + gps_position longitude; + template<class Archive> + void serialize(Archive &ar, const unsigned int version) + { + ar & latitude; + ar & longitude; + } +protected: + bus_stop(const gps_position & _lat, const gps_position & _long) : + latitude(_lat), longitude(_long) + {} +public: + bus_stop(){} + virtual ~bus_stop(){} +}; + +BOOST_SERIALIZATION_ASSUME_ABSTRACT(bus_stop) + +std::ostream & operator<<(std::ostream &os, const bus_stop &bs) +{ + return os << bs.latitude << bs.longitude << ' ' << bs.description(); +} + +///////////////////////////////////////////////////////////// +// Several kinds of bus stops +// +// illustrates serialization of derived types +// +class bus_stop_corner : public bus_stop +{ + friend class boost::serialization::access; + std::string street1; + std::string street2; + virtual std::string description() const + { + return street1 + " and " + street2; + } + template<class Archive> + void serialize(Archive &ar, const unsigned int version) + { + // save/load base class information + ar & boost::serialization::base_object<bus_stop>(*this); + ar & street1 & street2; + } + +public: + bus_stop_corner(){} + bus_stop_corner(const gps_position & _lat, const gps_position & _long, + const std::string & _s1, const std::string & _s2 + ) : + bus_stop(_lat, _long), street1(_s1), street2(_s2) + { + } +}; + +class bus_stop_destination : public bus_stop +{ + friend class boost::serialization::access; + std::string name; + virtual std::string description() const + { + return name; + } + template<class Archive> + void serialize(Archive &ar, const unsigned int version) + { + ar & boost::serialization::base_object<bus_stop>(*this) & name; + } +public: + + bus_stop_destination(){} + bus_stop_destination( + const gps_position & _lat, const gps_position & _long, const std::string & _name + ) : + bus_stop(_lat, _long), name(_name) + { + } +}; + +///////////////////////////////////////////////////////////// +// a bus route is a collection of bus stops +// +// illustrates serialization of STL collection templates. +// +// illustrates serialzation of polymorphic pointer (bus stop *); +// +// illustrates storage and recovery of shared pointers is correct +// and efficient. That is objects pointed to by more than one +// pointer are stored only once. In such cases only one such +// object is restored and pointers are restored to point to it +// +class bus_route +{ + friend class boost::serialization::access; + friend std::ostream & operator<<(std::ostream &os, const bus_route &br); + typedef bus_stop * bus_stop_pointer; + std::list<bus_stop_pointer> stops; + template<class Archive> + void serialize(Archive &ar, const unsigned int version) + { + // in this program, these classes are never serialized directly but rather + // through a pointer to the base class bus_stop. So we need a way to be + // sure that the archive contains information about these derived classes. + //ar.template register_type<bus_stop_corner>(); + ar.register_type(static_cast<bus_stop_corner *>(NULL)); + //ar.template register_type<bus_stop_destination>(); + ar.register_type(static_cast<bus_stop_destination *>(NULL)); + // serialization of stl collections is already defined + // in the header + ar & stops; + } +public: + bus_route(){} + void append(bus_stop *_bs) + { + stops.insert(stops.end(), _bs); + } +}; +std::ostream & operator<<(std::ostream &os, const bus_route &br) +{ + std::list<bus_stop *>::const_iterator it; + // note: we're displaying the pointer to permit verification + // that duplicated pointers are properly restored. + for(it = br.stops.begin(); it != br.stops.end(); it++){ + os << '\n' << std::hex << "0x" << *it << std::dec << ' ' << **it; + } + return os; +} + +///////////////////////////////////////////////////////////// +// a bus schedule is a collection of routes each with a starting time +// +// Illustrates serialization of STL objects(pair) in a non-intrusive way. +// See definition of operator<< <pair<F, S> >(ar, pair) and others in +// serialization.hpp +// +// illustrates nesting of serializable classes +// +// illustrates use of version number to automatically grandfather older +// versions of the same class. + +class bus_schedule +{ +public: + // note: this structure was made public. because the friend declarations + // didn't seem to work as expected. + struct trip_info + { + template<class Archive> + void serialize(Archive &ar, const unsigned int file_version) + { + // in versions 2 or later + if(file_version >= 2) + // read the drivers name + ar & driver; + // all versions have the follwing info + ar & hour & minute; + } + + // starting time + int hour; + int minute; + // only after system shipped was the driver's name added to the class + std::string driver; + + trip_info(){} + trip_info(int _h, int _m, const std::string &_d) : + hour(_h), minute(_m), driver(_d) + {} + }; +private: + friend class boost::serialization::access; + friend std::ostream & operator<<(std::ostream &os, const bus_schedule &bs); + friend std::ostream & operator<<(std::ostream &os, const bus_schedule::trip_info &ti); + std::list<std::pair<trip_info, bus_route *> > schedule; + template<class Archive> + void serialize(Archive &ar, const unsigned int version) + { + ar & schedule; + } +public: + void append(const std::string &_d, int _h, int _m, bus_route *_br) + { + schedule.insert(schedule.end(), std::make_pair(trip_info(_h, _m, _d), _br)); + } + bus_schedule(){} +}; +BOOST_CLASS_VERSION(bus_schedule::trip_info, 2) + +std::ostream & operator<<(std::ostream &os, const bus_schedule::trip_info &ti) +{ + return os << '\n' << ti.hour << ':' << ti.minute << ' ' << ti.driver << ' '; +} +std::ostream & operator<<(std::ostream &os, const bus_schedule &bs) +{ + std::list<std::pair<bus_schedule::trip_info, bus_route *> >::const_iterator it; + for(it = bs.schedule.begin(); it != bs.schedule.end(); it++){ + os << it->first << *(it->second); + } + return os; +} + +void save_schedule(const bus_schedule &s, const char * filename){ + // make an archive + std::ofstream ofs(filename); + boost::archive::text_oarchive oa(ofs); + oa << s; +} + +void +restore_schedule(bus_schedule &s, const char * filename) +{ + // open the archive + std::ifstream ifs(filename); + boost::archive::text_iarchive ia(ifs); + + // restore the schedule from the archive + ia >> s; +} + +int main(int argc, char *argv[]) +{ + // make the schedule + bus_schedule original_schedule; + + // fill in the data + // make a few stops + bus_stop *bs0 = new bus_stop_corner( + gps_position(34, 135, 52.560f), + gps_position(134, 22, 78.30f), + "24th Street", "10th Avenue" + ); + bus_stop *bs1 = new bus_stop_corner( + gps_position(35, 137, 23.456f), + gps_position(133, 35, 54.12f), + "State street", "Cathedral Vista Lane" + ); + bus_stop *bs2 = new bus_stop_destination( + gps_position(35, 136, 15.456f), + gps_position(133, 32, 15.300f), + "White House" + ); + bus_stop *bs3 = new bus_stop_destination( + gps_position(35, 134, 48.789f), + gps_position(133, 32, 16.230f), + "Lincoln Memorial" + ); + + // make a routes + bus_route route0; + route0.append(bs0); + route0.append(bs1); + route0.append(bs2); + + // add trips to schedule + original_schedule.append("bob", 6, 24, &route0); + original_schedule.append("bob", 9, 57, &route0); + original_schedule.append("alice", 11, 02, &route0); + + // make aother routes + bus_route route1; + route1.append(bs3); + route1.append(bs2); + route1.append(bs1); + + // add trips to schedule + original_schedule.append("ted", 7, 17, &route1); + original_schedule.append("ted", 9, 38, &route1); + original_schedule.append("alice", 11, 47, &route1); + + // display the complete schedule + std::cout << "original schedule"; + std::cout << original_schedule; + + std::string filename(boost::archive::tmpdir()); + filename += "/demofile.txt"; + + // save the schedule + save_schedule(original_schedule, filename.c_str()); + + // ... some time later + // make a new schedule + bus_schedule new_schedule; + + restore_schedule(new_schedule, filename.c_str()); + + // and display + std::cout << "\nrestored schedule"; + std::cout << new_schedule; + // should be the same as the old one. (except for the pointer values) + + delete bs0; + delete bs1; + delete bs2; + delete bs3; + return 0; +} diff --git a/src/boost/libs/serialization/example/demo_auto_ptr.cpp b/src/boost/libs/serialization/example/demo_auto_ptr.cpp new file mode 100644 index 00000000..0cca0afe --- /dev/null +++ b/src/boost/libs/serialization/example/demo_auto_ptr.cpp @@ -0,0 +1,135 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// demo_auto_ptr.cpp + +// (C) Copyright 2002-4 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +#include <list> +#include <memory> +#include <fstream> +#include <string> + +#include <cstdio> // remove, std::autoptr inteface wrong in dinkumware +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include <boost/archive/tmpdir.hpp> +#include <boost/archive/text_oarchive.hpp> +#include <boost/archive/text_iarchive.hpp> + +#include <boost/serialization/split_free.hpp> + +namespace boost { +namespace serialization { + +///////////////////////////////////////////////////////////// +// implement serialization for auto_ptr< T > +// note: this must be added to the boost namespace in order to +// be called by the library +template<class Archive, class T> +inline void save( + Archive & ar, + const std::auto_ptr< T > &t, + const unsigned int file_version +){ + // only the raw pointer has to be saved + // the ref count is rebuilt automatically on load + const T * const tx = t.get(); + ar << tx; +} + +template<class Archive, class T> +inline void load( + Archive & ar, + std::auto_ptr< T > &t, + const unsigned int file_version +){ + T *pTarget; + ar >> pTarget; + // note that the reset automagically maintains the reference count + #if BOOST_WORKAROUND(BOOST_DINKUMWARE_STDLIB, == 1) + t.release(); + t = std::auto_ptr< T >(pTarget); + #else + t.reset(pTarget); + #endif +} + +// split non-intrusive serialization function member into separate +// non intrusive save/load member functions +template<class Archive, class T> +inline void serialize( + Archive & ar, + std::auto_ptr< T > &t, + const unsigned int file_version +){ + boost::serialization::split_free(ar, t, file_version); +} + +} // namespace serialization +} // namespace boost + +///////////////////////////////////////////////////////////// +// test auto_ptr serialization +class A +{ +private: + friend class boost::serialization::access; + int x; + template<class Archive> + void serialize(Archive &ar, const unsigned int /* file_version */){ + ar & x; + } +public: + A(){} // default constructor + ~A(){} // default destructor +}; + +void save(const std::auto_ptr<A> & spa, const char *filename) +{ + std::ofstream ofs(filename); + boost::archive::text_oarchive oa(ofs); + oa << spa; +} + +void load(std::auto_ptr<A> & spa, const char *filename) +{ + // open the archive + std::ifstream ifs(filename); + boost::archive::text_iarchive ia(ifs); + + // restore the schedule from the archive + ia >> spa; +} + +int main(int argc, char *argv[]) +{ + std::string filename = boost::archive::tmpdir(); + filename += "/testfile"; + + // create a new auto pointer to ta new object of type A + std::auto_ptr<A> spa(new A); + // serialize it + save(spa, filename.c_str()); + // reset the auto pointer to NULL + // thereby destroying the object of type A + // note that the reset automagically maintains the reference count + #if BOOST_WORKAROUND(BOOST_DINKUMWARE_STDLIB, == 1) + spa.release(); + #else + spa.reset(); + #endif + // restore state to one equivalent to the original + // creating a new type A object + load(spa, filename.c_str()); + // obj of type A gets destroyed + // as auto_ptr goes out of scope + std::remove(filename.c_str()); + return 0; +} diff --git a/src/boost/libs/serialization/example/demo_dll_a.hpp b/src/boost/libs/serialization/example/demo_dll_a.hpp new file mode 100644 index 00000000..7adbfe02 --- /dev/null +++ b/src/boost/libs/serialization/example/demo_dll_a.hpp @@ -0,0 +1,318 @@ +#ifndef BOOST_SERIALIZATION_TEST_A_HPP +#define BOOST_SERIALIZATION_TEST_A_HPP + +// MS compatible compilers support #pragma once +#if defined(_MSC_VER) +# pragma once +#endif + +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// A.hpp simple class test + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <cassert> +#include <cstdlib> // for rand() +#include <cmath> // for fabs() +#include <cstddef> // size_t +#include <boost/math/special_functions/next.hpp> + +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::rand; + using ::fabs; + using ::size_t; +} +#endif + +//#include <boost/test/test_exec_monitor.hpp> +#include <boost/limits.hpp> +#include <boost/cstdint.hpp> + +#include <boost/detail/workaround.hpp> +#if BOOST_WORKAROUND(BOOST_DINKUMWARE_STDLIB, == 1) +#include <boost/archive/dinkumware.hpp> +#endif + +#include <boost/serialization/nvp.hpp> +#include <boost/serialization/string.hpp> +#include <boost/serialization/access.hpp> + +class A +{ +private: + friend class boost::serialization::access; + // note: from an aesthetic perspective, I would much prefer to have this + // defined out of line. Unfortunately, this trips a bug in the VC 6.0 + // compiler. So hold our nose and put it her to permit running of tests. + template<class Archive> + void serialize( + Archive &ar, + const unsigned int /* file_version */ + ){ + ar & BOOST_SERIALIZATION_NVP(b); + #ifndef BOOST_NO_INT64_T + ar & BOOST_SERIALIZATION_NVP(f); + ar & BOOST_SERIALIZATION_NVP(g); + #endif + #if BOOST_WORKAROUND(__BORLANDC__, <= 0x551 ) + int i; + if(BOOST_DEDUCED_TYPENAME Archive::is_saving::value){ + i = l; + ar & BOOST_SERIALIZATION_NVP(i); + } + else{ + ar & BOOST_SERIALIZATION_NVP(i); + l = i; + } + #else + ar & BOOST_SERIALIZATION_NVP(l); + #endif + ar & BOOST_SERIALIZATION_NVP(m); + ar & BOOST_SERIALIZATION_NVP(n); + ar & BOOST_SERIALIZATION_NVP(o); + ar & BOOST_SERIALIZATION_NVP(p); + ar & BOOST_SERIALIZATION_NVP(q); + #ifndef BOOST_NO_CWCHAR + ar & BOOST_SERIALIZATION_NVP(r); + #endif + ar & BOOST_SERIALIZATION_NVP(c); + ar & BOOST_SERIALIZATION_NVP(s); + ar & BOOST_SERIALIZATION_NVP(t); + ar & BOOST_SERIALIZATION_NVP(u); + ar & BOOST_SERIALIZATION_NVP(v); + ar & BOOST_SERIALIZATION_NVP(w); + ar & BOOST_SERIALIZATION_NVP(x); + ar & BOOST_SERIALIZATION_NVP(y); + #ifndef BOOST_NO_STD_WSTRING + ar & BOOST_SERIALIZATION_NVP(z); + #endif + } + bool b; + #ifndef BOOST_NO_INT64_T + boost::int64_t f; + boost::uint64_t g; + #endif + enum h { + i = 0, + j, + k + } l; + std::size_t m; + signed long n; + unsigned long o; + signed short p; + unsigned short q; + #ifndef BOOST_NO_CWCHAR + wchar_t r; + #endif + char c; + signed char s; + unsigned char t; + signed int u; + unsigned int v; + float w; + double x; + std::string y; + #ifndef BOOST_NO_STD_WSTRING + std::wstring z; + #endif +public: + A(); + bool operator==(const A &rhs) const; + bool operator!=(const A &rhs) const; + bool operator<(const A &rhs) const; // used by less + // hash function for class A + operator std::size_t () const; + friend std::ostream & operator<<(std::ostream & os, A const & a); + friend std::istream & operator>>(std::istream & is, A & a); +}; + +//BOOST_TEST_DONT_PRINT_LOG_VALUE(A); + +template<class S> +void randomize(S &x) +{ + assert(0 == x.size()); + for(;;){ + unsigned int i = std::rand() % 27; + if(0 == i) + break; + x += static_cast<BOOST_DEDUCED_TYPENAME S::value_type>('a' - 1 + i); + } +} + +template<class T> +void accumulate(std::size_t & s, const T & t){ + const char * tptr = (const char *)(& t); + unsigned int count = sizeof(t); + while(count-- > 0){ + s += *tptr++; + } +} + +A::operator std::size_t () const { + std::size_t retval = 0; + accumulate(retval, b); + #ifndef BOOST_NO_INT64_T + accumulate(retval, f); + accumulate(retval, g); + #endif + accumulate(retval, l); + accumulate(retval, m); + accumulate(retval, n); + accumulate(retval, o); + accumulate(retval, p); + accumulate(retval, q); + #ifndef BOOST_NO_CWCHAR + accumulate(retval, r); + #endif + accumulate(retval, c); + accumulate(retval, s); + accumulate(retval, t); + accumulate(retval, u); + accumulate(retval, v); + return retval; +} + +inline A::A() : + b(true), + #ifndef BOOST_NO_INT64_T + f(std::rand() * std::rand()), + g(std::rand() * std::rand()), + #endif + l(static_cast<enum h>(std::rand() % 3)), + m(std::rand()), + n(std::rand()), + o(std::rand()), + p(std::rand()), + q(std::rand()), + #ifndef BOOST_NO_CWCHAR + r(std::rand()), + #endif + c(std::rand()), + s(std::rand()), + t(std::rand()), + u(std::rand()), + v(std::rand()), + w((float)std::rand()), + x((double)std::rand()) +{ + randomize(y); + #ifndef BOOST_NO_STD_WSTRING + randomize(z); + #endif +} + +inline bool A::operator==(const A &rhs) const +{ + if(b != rhs.b) + return false; + if(l != rhs.l) + return false; + #ifndef BOOST_NO_INT64_T + if(f != rhs.f) + return false; + if(g != rhs.g) + return false; + #endif + if(m != rhs.m) + return false; + if(n != rhs.n) + return false; + if(o != rhs.o) + return false; + if(p != rhs.p) + return false; + if(q != rhs.q) + return false; + #ifndef BOOST_NO_CWCHAR + if(r != rhs.r) + return false; + #endif + if(c != rhs.c) + return false; + if(s != rhs.s) + return false; + if(t != rhs.t) + return false; + if(u != rhs.u) + return false; + if(v != rhs.v) + return false; + if(std::abs( boost::math::float_distance(w, rhs.w)) > 1) + return false; + if(std::abs( boost::math::float_distance(x, rhs.x)) > 1) + return false; + if(0 != y.compare(rhs.y)) + return false; + #ifndef BOOST_NO_STD_WSTRING + if(0 != z.compare(rhs.z)) + return false; + #endif + return true; +} + +inline bool A::operator!=(const A &rhs) const +{ + return ! (*this == rhs); +} + +inline bool A::operator<(const A &rhs) const +{ + if(b != rhs.b) + return b < rhs.b; + #ifndef BOOST_NO_INT64_T + if(f != rhs.f) + return f < rhs.f; + if(g != rhs.g) + return g < rhs.g; + #endif + if(l != rhs.l ) + return l < rhs.l; + if(m != rhs.m ) + return m < rhs.m; + if(n != rhs.n ) + return n < rhs.n; + if(o != rhs.o ) + return o < rhs.o; + if(p != rhs.p ) + return p < rhs.p; + if(q != rhs.q ) + return q < rhs.q; + #ifndef BOOST_NO_CWCHAR + if(r != rhs.r ) + return r < rhs.r; + #endif + if(c != rhs.c ) + return c < rhs.c; + if(s != rhs.s ) + return s < rhs.s; + if(t != rhs.t ) + return t < rhs.t; + if(u != rhs.u ) + return u < rhs.u; + if(v != rhs.v ) + return v < rhs.v; + if(w != rhs.w ) + return w < rhs.w; + if(x != rhs.x ) + return x < rhs.x; + int i = y.compare(rhs.y); + if(i != 0 ) + return i < 0; + #ifndef BOOST_NO_STD_WSTRING + int j = z.compare(rhs.z); + if(j != 0 ) + return j < 0; + #endif + return false; +} + +#endif // BOOST_SERIALIZATION_TEST_A_HPP diff --git a/src/boost/libs/serialization/example/demo_dll_a.ipp b/src/boost/libs/serialization/example/demo_dll_a.ipp new file mode 100644 index 00000000..99cc9fe6 --- /dev/null +++ b/src/boost/libs/serialization/example/demo_dll_a.ipp @@ -0,0 +1,317 @@ +#ifndef BOOST_SERIALIZATION_TEST_A_HPP +#define BOOST_SERIALIZATION_TEST_A_HPP + +// MS compatible compilers support #pragma once +#if defined(_MSC_VER) +# pragma once +#endif + +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// A.hpp simple class test + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <cassert> +#include <cstdlib> // for rand() +#include <cmath> // for fabs() +#include <cstddef> // size_t + +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::rand; + using ::fabs; + using ::size_t; +} +#endif + +//#include <boost/test/test_exec_monitor.hpp> +#include <boost/limits.hpp> +#include <boost/cstdint.hpp> + +#include <boost/detail/workaround.hpp> +#if BOOST_WORKAROUND(BOOST_DINKUMWARE_STDLIB, == 1) +#include <boost/archive/dinkumware.hpp> +#endif + +#include <boost/serialization/nvp.hpp> +#include <boost/serialization/string.hpp> +#include <boost/serialization/access.hpp> + +class A +{ +private: + friend class boost::serialization::access; + // note: from an aesthetic perspective, I would much prefer to have this + // defined out of line. Unfortunately, this trips a bug in the VC 6.0 + // compiler. So hold our nose and put it her to permit running of tests. + template<class Archive> + void serialize( + Archive &ar, + const unsigned int /* file_version */ + ){ + ar & BOOST_SERIALIZATION_NVP(b); + #ifndef BOOST_NO_INT64_T + ar & BOOST_SERIALIZATION_NVP(f); + ar & BOOST_SERIALIZATION_NVP(g); + #endif + #if BOOST_WORKAROUND(__BORLANDC__, <= 0x551 ) + int i; + if(BOOST_DEDUCED_TYPENAME Archive::is_saving::value){ + i = l; + ar & BOOST_SERIALIZATION_NVP(i); + } + else{ + ar & BOOST_SERIALIZATION_NVP(i); + l = i; + } + #else + ar & BOOST_SERIALIZATION_NVP(l); + #endif + ar & BOOST_SERIALIZATION_NVP(m); + ar & BOOST_SERIALIZATION_NVP(n); + ar & BOOST_SERIALIZATION_NVP(o); + ar & BOOST_SERIALIZATION_NVP(p); + ar & BOOST_SERIALIZATION_NVP(q); + #ifndef BOOST_NO_CWCHAR + ar & BOOST_SERIALIZATION_NVP(r); + #endif + ar & BOOST_SERIALIZATION_NVP(c); + ar & BOOST_SERIALIZATION_NVP(s); + ar & BOOST_SERIALIZATION_NVP(t); + ar & BOOST_SERIALIZATION_NVP(u); + ar & BOOST_SERIALIZATION_NVP(v); + ar & BOOST_SERIALIZATION_NVP(w); + ar & BOOST_SERIALIZATION_NVP(x); + ar & BOOST_SERIALIZATION_NVP(y); + #ifndef BOOST_NO_STD_WSTRING + ar & BOOST_SERIALIZATION_NVP(z); + #endif + } + bool b; + #ifndef BOOST_NO_INT64_T + boost::int64_t f; + boost::uint64_t g; + #endif + enum h { + i = 0, + j, + k + } l; + std::size_t m; + signed long n; + unsigned long o; + signed short p; + unsigned short q; + #ifndef BOOST_NO_CWCHAR + wchar_t r; + #endif + char c; + signed char s; + unsigned char t; + signed int u; + unsigned int v; + float w; + double x; + std::string y; + #ifndef BOOST_NO_STD_WSTRING + std::wstring z; + #endif +public: + A(); + bool operator==(const A &rhs) const; + bool operator!=(const A &rhs) const; + bool operator<(const A &rhs) const; // used by less + // hash function for class A + operator std::size_t () const; + friend std::ostream & operator<<(std::ostream & os, A const & a); + friend std::istream & operator>>(std::istream & is, A & a); +}; + +//BOOST_TEST_DONT_PRINT_LOG_VALUE(A); + +template<class S> +void randomize(S &x) +{ + assert(0 == x.size()); + for(;;){ + unsigned int i = std::rand() % 27; + if(0 == i) + break; + x += static_cast<BOOST_DEDUCED_TYPENAME S::value_type>('a' - 1 + i); + } +} + +template<class T> +void accumulate(std::size_t & s, const T & t){ + const char * tptr = (const char *)(& t); + unsigned int count = sizeof(t); + while(count-- > 0){ + s += *tptr++; + } +} + +A::operator std::size_t () const { + std::size_t retval = 0; + accumulate(retval, b); + #ifndef BOOST_NO_INT64_T + accumulate(retval, f); + accumulate(retval, g); + #endif + accumulate(retval, l); + accumulate(retval, m); + accumulate(retval, n); + accumulate(retval, o); + accumulate(retval, p); + accumulate(retval, q); + #ifndef BOOST_NO_CWCHAR + accumulate(retval, r); + #endif + accumulate(retval, c); + accumulate(retval, s); + accumulate(retval, t); + accumulate(retval, u); + accumulate(retval, v); + return retval; +} + +inline A::A() : + b(true), + #ifndef BOOST_NO_INT64_T + f(std::rand() * std::rand()), + g(std::rand() * std::rand()), + #endif + l(static_cast<enum h>(std::rand() % 3)), + m(std::rand()), + n(std::rand()), + o(std::rand()), + p(std::rand()), + q(std::rand()), + #ifndef BOOST_NO_CWCHAR + r(std::rand()), + #endif + c(std::rand()), + s(std::rand()), + t(std::rand()), + u(std::rand()), + v(std::rand()), + w((float)std::rand()), + x((double)std::rand()) +{ + randomize(y); + #ifndef BOOST_NO_STD_WSTRING + randomize(z); + #endif +} + +inline bool A::operator==(const A &rhs) const +{ + if(b != rhs.b) + return false; + if(l != rhs.l) + return false; + #ifndef BOOST_NO_INT64_T + if(f != rhs.f) + return false; + if(g != rhs.g) + return false; + #endif + if(m != rhs.m) + return false; + if(n != rhs.n) + return false; + if(o != rhs.o) + return false; + if(p != rhs.p) + return false; + if(q != rhs.q) + return false; + #ifndef BOOST_NO_CWCHAR + if(r != rhs.r) + return false; + #endif + if(c != rhs.c) + return false; + if(s != rhs.s) + return false; + if(t != rhs.t) + return false; + if(u != rhs.u) + return false; + if(v != rhs.v) + return false; + if(std::abs( boost::math::float_distance(w, rhs.w)) > 1) + return false; + if(std::abs( boost::math::float_distance(x, rhs.x)) > 1) + return false; + if(0 != y.compare(rhs.y)) + return false; + #ifndef BOOST_NO_STD_WSTRING + if(0 != z.compare(rhs.z)) + return false; + #endif + return true; +} + +inline bool A::operator!=(const A &rhs) const +{ + return ! (*this == rhs); +} + +inline bool A::operator<(const A &rhs) const +{ + if(b != rhs.b) + return b < rhs.b; + #ifndef BOOST_NO_INT64_T + if(f != rhs.f) + return f < rhs.f; + if(g != rhs.g) + return g < rhs.g; + #endif + if(l != rhs.l ) + return l < rhs.l; + if(m != rhs.m ) + return m < rhs.m; + if(n != rhs.n ) + return n < rhs.n; + if(o != rhs.o ) + return o < rhs.o; + if(p != rhs.p ) + return p < rhs.p; + if(q != rhs.q ) + return q < rhs.q; + #ifndef BOOST_NO_CWCHAR + if(r != rhs.r ) + return r < rhs.r; + #endif + if(c != rhs.c ) + return c < rhs.c; + if(s != rhs.s ) + return s < rhs.s; + if(t != rhs.t ) + return t < rhs.t; + if(u != rhs.u ) + return u < rhs.u; + if(v != rhs.v ) + return v < rhs.v; + if(w != rhs.w ) + return w < rhs.w; + if(x != rhs.x ) + return x < rhs.x; + int i = y.compare(rhs.y); + if(i != 0 ) + return i < 0; + #ifndef BOOST_NO_STD_WSTRING + int j = z.compare(rhs.z); + if(j != 0 ) + return j < 0; + #endif + return false; +} + +#endif // BOOST_SERIALIZATION_TEST_A_HPP diff --git a/src/boost/libs/serialization/example/demo_dll_b.hpp b/src/boost/libs/serialization/example/demo_dll_b.hpp new file mode 100644 index 00000000..0b3d102d --- /dev/null +++ b/src/boost/libs/serialization/example/demo_dll_b.hpp @@ -0,0 +1,113 @@ +#ifndef BOOST_SERIALIZATION_TEST_B_HPP +#define BOOST_SERIALIZATION_TEST_B_HPP + +// MS compatible compilers support #pragma once +#if defined(_MSC_VER) +# pragma once +#endif + +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// B.hpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <cstdlib> // for rand() +#include <boost/math/special_functions/next.hpp> + +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::rand; +} +#endif + +#include <boost/serialization/version.hpp> +#include <boost/serialization/split_member.hpp> +#include <boost/serialization/base_object.hpp> + +#include "A.hpp" + +/////////////////////////////////////////////////////// +// Derived class test +class B : public A +{ +private: + friend class boost::serialization::access; + template<class Archive> + void save(Archive &ar, const unsigned int /* file_version */) const + { + // write any base class info to the archive + ar << BOOST_SERIALIZATION_BASE_OBJECT_NVP(A); + + // write out members + ar << BOOST_SERIALIZATION_NVP(s); + ar << BOOST_SERIALIZATION_NVP(t); + ar << BOOST_SERIALIZATION_NVP(u); + ar << BOOST_SERIALIZATION_NVP(v); + ar << BOOST_SERIALIZATION_NVP(w); + ar << BOOST_SERIALIZATION_NVP(x); + } + + template<class Archive> + void load(Archive & ar, const unsigned int file_version) + { + // read any base class info to the archive + ar >> BOOST_SERIALIZATION_BASE_OBJECT_NVP(A); + switch(file_version){ + case 1: + case 2: + ar >> BOOST_SERIALIZATION_NVP(s); + ar >> BOOST_SERIALIZATION_NVP(t); + ar >> BOOST_SERIALIZATION_NVP(u); + ar >> BOOST_SERIALIZATION_NVP(v); + ar >> BOOST_SERIALIZATION_NVP(w); + ar >> BOOST_SERIALIZATION_NVP(x); + default: + break; + } + } + + BOOST_SERIALIZATION_SPLIT_MEMBER() + signed char s; + unsigned char t; + signed int u; + unsigned int v; + float w; + double x; +public: + B(); + virtual ~B(){}; + bool operator==(const B &rhs) const; +}; + +B::B() : + s(std::rand()), + t(std::rand()), + u(std::rand()), + v(std::rand()), + w((float)std::rand() / std::rand()), + x((double)std::rand() / std::rand()) +{ +} + +BOOST_CLASS_VERSION(B, 2) + +inline bool B::operator==(const B &rhs) const +{ + return + A::operator==(rhs) + && s == rhs.s + && t == rhs.t + && u == rhs.u + && v == rhs.v + && std::abs( boost::math::float_distance(w, rhs.w)) < 2 + && std::abs( boost::math::float_distance(x, rhs.x)) < 2 + ; +} + +#endif // BOOST_SERIALIZATION_TEST_B_HPP diff --git a/src/boost/libs/serialization/example/demo_dll_b.ipp b/src/boost/libs/serialization/example/demo_dll_b.ipp new file mode 100644 index 00000000..74d53b79 --- /dev/null +++ b/src/boost/libs/serialization/example/demo_dll_b.ipp @@ -0,0 +1,112 @@ +#ifndef BOOST_SERIALIZATION_TEST_B_HPP +#define BOOST_SERIALIZATION_TEST_B_HPP + +// MS compatible compilers support #pragma once +#if defined(_MSC_VER) +# pragma once +#endif + +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// B.hpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <cstdlib> // for rand() + +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::rand; +} +#endif + +#include <boost/serialization/version.hpp> +#include <boost/serialization/split_member.hpp> +#include <boost/serialization/base_object.hpp> + +#include "A.hpp" + +/////////////////////////////////////////////////////// +// Derived class test +class B : public A +{ +private: + friend class boost::serialization::access; + template<class Archive> + void save(Archive &ar, const unsigned int /* file_version */) const + { + // write any base class info to the archive + ar << BOOST_SERIALIZATION_BASE_OBJECT_NVP(A); + + // write out members + ar << BOOST_SERIALIZATION_NVP(s); + ar << BOOST_SERIALIZATION_NVP(t); + ar << BOOST_SERIALIZATION_NVP(u); + ar << BOOST_SERIALIZATION_NVP(v); + ar << BOOST_SERIALIZATION_NVP(w); + ar << BOOST_SERIALIZATION_NVP(x); + } + + template<class Archive> + void load(Archive & ar, const unsigned int file_version) + { + // read any base class info to the archive + ar >> BOOST_SERIALIZATION_BASE_OBJECT_NVP(A); + switch(file_version){ + case 1: + case 2: + ar >> BOOST_SERIALIZATION_NVP(s); + ar >> BOOST_SERIALIZATION_NVP(t); + ar >> BOOST_SERIALIZATION_NVP(u); + ar >> BOOST_SERIALIZATION_NVP(v); + ar >> BOOST_SERIALIZATION_NVP(w); + ar >> BOOST_SERIALIZATION_NVP(x); + default: + break; + } + } + + BOOST_SERIALIZATION_SPLIT_MEMBER() + signed char s; + unsigned char t; + signed int u; + unsigned int v; + float w; + double x; +public: + B(); + virtual ~B(){}; + bool operator==(const B &rhs) const; +}; + +B::B() : + s(std::rand()), + t(std::rand()), + u(std::rand()), + v(std::rand()), + w((float)std::rand() / std::rand()), + x((double)std::rand() / std::rand()) +{ +} + +BOOST_CLASS_VERSION(B, 2) + +inline bool B::operator==(const B &rhs) const +{ + return + A::operator==(rhs) + && s == rhs.s + && t == rhs.t + && u == rhs.u + && v == rhs.v + && std::abs( boost::math::float_distance(w, rhs.w)) < 2 + && std::abs( boost::math::float_distance(x, rhs.x)) < 2 + ; +} + +#endif // BOOST_SERIALIZATION_TEST_B_HPP diff --git a/src/boost/libs/serialization/example/demo_exception.cpp b/src/boost/libs/serialization/example/demo_exception.cpp new file mode 100644 index 00000000..122a05a0 --- /dev/null +++ b/src/boost/libs/serialization/example/demo_exception.cpp @@ -0,0 +1,258 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// demo_exception.cpp + +// (C) Copyright 2002-4 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// Example of safe exception handling for pointer de-serialization +// +// This example was prepared by Robert Ramey to demonstrate and test +// safe exception handling during the de-serialization of pointers in +// a non-trivial example. +// +// Hopefully, this addresses exception issues raised by +// Vahan Margaryan who spent considerable time and effort +// in the analysis and testing of issues of exception safety +// of the serialization library. + +#include <algorithm> +#include <iostream> +#include <cstddef> // NULL +#include <fstream> +#include <string> + +#include <cstdio> // remove +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include <boost/archive/tmpdir.hpp> + +#ifndef BOOST_NO_EXCEPTIONS +#include <exception> +#endif + +#include <boost/archive/text_iarchive.hpp> +#include <boost/archive/text_oarchive.hpp> + +#include <boost/serialization/list.hpp> +#include <boost/serialization/split_member.hpp> + +template<class TPTR> +struct deleter +{ + void operator()(TPTR t){ + delete t; + } +}; + +class Course; +class Student; + +class Student +{ +public: + static int count; + Student(){ + count++; + } + ~Student(){ + some_courses.clear(); + count--; + } + std::list<Course *> some_courses; +private: + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive & ar, const unsigned int /* file_version */){ + ar & some_courses; + } +}; + +int Student::count = 0; + +class Course +{ +public: + static int count; + Course(){ + count++; + } + ~Course(){ + // doesnt delete pointers in list + // since it doesn't "own" them + some_students.clear(); + count--; + } + std::list<Student *> some_students; +private: + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive & ar, const unsigned int /* file_version */){ + ar & some_students; + } +}; + +int Course::count = 0; + +class School +{ +public: + ~School(){ + // must delete all the students because + // it "owns" them + std::for_each(all_students.begin(), all_students.end(), deleter<Student *>()); + all_students.clear(); + // as well as courses + std::for_each(all_courses.begin(), all_courses.end(), deleter<Course *>()); + all_courses.clear(); + } + std::list<Student *> all_students; + std::list<Course *> all_courses; +private: + friend class boost::serialization::access; + BOOST_SERIALIZATION_SPLIT_MEMBER() + template<class Archive> + void save(Archive & ar, const unsigned int file_version) const; + template<class Archive> + void load(Archive & ar, const unsigned int file_version); +}; + +#if 0 +// case 1: +template<class Archive> +void School::serialize(Archive & ar, const unsigned int /* file_version */){ + // if an exeception occurs while loading courses + // the structure courses may have some courses each + // with students + ar & all_courses; + // while all_students will have no members. + ar & all_students; // create students that have no courses + // so ~School() will delete all members of courses + // but this will NOT delete any students - see above + // a memory leak will be the result. +} + +// switching the order of serialization doesn't help in this case +// case 2: +template<class Archive> +void School::serialize(Archive & ar, const unsigned int /* file_version */){ + ar & all_students; + ar >> all_courses; // create any courses that have no students +} +#endif + +template<class Archive> +void School::save(Archive & ar, const unsigned int /* file_version */) const { + ar << all_students; + ar << all_courses; +} + +template<class Archive> +void School::load(Archive & ar, const unsigned int /* file_version */){ + // if an exeception occurs while loading courses + // the structure courses may have some courses each + // with students + try{ + // deserialization of a Course * will in general provoke the + // deserialization of Student * which are added to the list of + // students for a class. That is, this process will result + // in the copying of a pointer. + ar >> all_courses; + ar >> all_students; // create students that have no courses + } + catch(std::exception){ + // elminate any dangling references + all_courses.clear(); + all_students.clear(); + throw; + } +} + +void init(School *school){ + Student *bob = new Student(); + Student *ted = new Student(); + Student *carol = new Student(); + Student *alice = new Student(); + + school->all_students.push_back(bob); + school->all_students.push_back(ted); + school->all_students.push_back(carol); + school->all_students.push_back(alice); + + Course *math = new Course(); + Course *history = new Course(); + Course *literature = new Course(); + Course *gym = new Course(); + + school->all_courses.push_back(math); + school->all_courses.push_back(history); + school->all_courses.push_back(literature); + school->all_courses.push_back(gym); + + bob->some_courses.push_back(math); + math->some_students.push_back(bob); + bob->some_courses.push_back(literature); + literature->some_students.push_back(bob); + + ted->some_courses.push_back(math); + math->some_students.push_back(ted); + ted->some_courses.push_back(history); + history->some_students.push_back(ted); + + alice->some_courses.push_back(literature); + literature->some_students.push_back(alice); + alice->some_courses.push_back(history); + history->some_students.push_back(alice); + + // no students signed up for gym + // carol has no courses +} + +void save(const School * const school, const char *filename){ + std::ofstream ofile(filename); + boost::archive::text_oarchive ar(ofile); + ar << school; +} + +void load(School * & school, const char *filename){ + std::ifstream ifile(filename); + boost::archive::text_iarchive ar(ifile); + try{ + ar >> school; + } + catch(std::exception){ + // eliminate dangling reference + school = NULL; + } +} + +int main(int argc, char *argv[]){ + std::string filename(boost::archive::tmpdir()); + filename += "/demofile.txt"; + + School *school = new School(); + std::cout << "1. student count = " << Student::count << std::endl; + std::cout << "2. class count = " << Course::count << std::endl; + init(school); + std::cout << "3. student count = " << Student::count << std::endl; + std::cout << "4. class count = " << Course::count << std::endl; + save(school, filename.c_str()); + delete school; + school = NULL; + std::cout << "5. student count = " << Student::count << std::endl; + std::cout << "6. class count = " << Course::count << std::endl; + load(school, filename.c_str()); + std::cout << "7. student count = " << Student::count << std::endl; + std::cout << "8. class count = " << Course::count << std::endl; + delete school; + std::cout << "9. student count = " << Student::count << std::endl; + std::cout << "10. class count = " << Course::count << std::endl; + std::remove(filename.c_str()); + return Student::count + Course::count; +} diff --git a/src/boost/libs/serialization/example/demo_fast_archive.cpp b/src/boost/libs/serialization/example/demo_fast_archive.cpp new file mode 100644 index 00000000..8e12fd3c --- /dev/null +++ b/src/boost/libs/serialization/example/demo_fast_archive.cpp @@ -0,0 +1,180 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// demo_fast_binary_archive.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution +#include <sstream> + +#include <boost/static_assert.hpp> +#include <boost/type_traits/is_array.hpp> + +#define BOOST_ARCHIVE_SOURCE +#include <boost/archive/binary_oarchive_impl.hpp> +#include <boost/archive/binary_iarchive_impl.hpp> +#include <boost/archive/detail/register_archive.hpp> + +// include template definitions for base classes used. Otherwise +// you'll get link failure with undefined symbols +#include <boost/archive/impl/basic_binary_oprimitive.ipp> +#include <boost/archive/impl/basic_binary_iprimitive.ipp> +#include <boost/archive/impl/basic_binary_oarchive.ipp> +#include <boost/archive/impl/basic_binary_iarchive.ipp> + +using namespace boost::archive; + +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// "Fast" output binary archive. This is a variation of the native binary +class fast_binary_oarchive : + // don't derive from binary_oarchive !!! + public binary_oarchive_impl< + fast_binary_oarchive, + std::ostream::char_type, + std::ostream::traits_type + > +{ + typedef fast_binary_oarchive derived_t; + typedef binary_oarchive_impl< + fast_binary_oarchive, + std::ostream::char_type, + std::ostream::traits_type + > base_t; +#ifndef BOOST_NO_MEMBER_TEMPLATE_FRIENDS +public: +#else + friend class boost::archive::detail::interface_oarchive<derived_t>; + friend class basic_binary_oarchive<derived_t>; + friend class basic_binary_oprimitive< + derived_t, + std::ostream::char_type, + std::ostream::traits_type + >; + friend class boost::archive::save_access; +#endif + // add base class to the places considered when matching + // save function to a specific set of arguments. Note, this didn't + // work on my MSVC 7.0 system using + // binary_oarchive_impl<derived_t>::load_override; + // so we use the sure-fire method below. This failed to work as well + template<class T> + void save_override(T & t){ + base_t::save_override(t); + // verify that this program is in fact working by making sure + // that arrays are getting passed here + BOOST_STATIC_ASSERT(! (boost::is_array<T>::value) ); + } + template<int N> + void save_override(const int (& t)[N]){ + save_binary(t, sizeof(t)); + } + template<int N> + void save_override(const unsigned int (& t)[N]){ + save_binary(t, sizeof(t)); + } + template<int N> + void save_override(const long (& t)[N]){ + save_binary(t, sizeof(t)); + } + template<int N> + void save_override(const unsigned long (& t)[N]){ + save_binary(t, sizeof(t)); + } +public: + fast_binary_oarchive(std::ostream & os, unsigned flags = 0) : + base_t(os, flags) + {} + fast_binary_oarchive(std::streambuf & bsb, unsigned int flags = 0) : + base_t(bsb, flags) + {} +}; + +// required by export +BOOST_SERIALIZATION_REGISTER_ARCHIVE(fast_binary_oarchive) + +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// "Fast" input binary archive. This is a variation of the native binary +class fast_binary_iarchive : + // don't derive from binary_oarchive !!! + public binary_iarchive_impl< + fast_binary_iarchive, + std::istream::char_type, + std::istream::traits_type + > +{ + typedef fast_binary_iarchive derived_t; + typedef binary_iarchive_impl< + fast_binary_iarchive, + std::istream::char_type, + std::istream::traits_type + > base_t; +#ifndef BOOST_NO_MEMBER_TEMPLATE_FRIENDS +public: +#else + friend class boost::archive::detail::interface_iarchive<derived_t>; + friend class basic_binary_iarchive<derived_t>; + friend class basic_binary_iprimitive< + derived_t, + std::ostream::char_type, + std::ostream::traits_type + >; + friend class boost::archive::load_access; +#endif + // add base class to the places considered when matching + // save function to a specific set of arguments. Note, this didn't + // work on my MSVC 7.0 system using + // binary_oarchive_impl<derived_t>::load_override; + // so we use the sure-fire method below. This failed to work as well + template<class T> + void load_override(T & t){ + base_t::load_override(t); + BOOST_STATIC_ASSERT(! (boost::is_array<T>::value) ); + } + template<int N> + void load_override(int (& t)[N]){ + load_binary(t, sizeof(t)); + } + template<int N> + void load_override(unsigned int (& t)[N]){ + load_binary(t, sizeof(t)); + } + template<int N> + void load_override(long (& t)[N]){ + load_binary(t, sizeof(t)); + } + template<int N> + void load_override(unsigned long (& t)[N]){ + load_binary(t, sizeof(t)); + } +public: + fast_binary_iarchive(std::istream & is, unsigned int flags = 0) : + base_t(is, flags) + {} + fast_binary_iarchive(std::streambuf & bsb, unsigned int flags = 0) : + base_t(bsb, flags) + {} +}; + +// required by export +BOOST_SERIALIZATION_REGISTER_ARCHIVE(fast_binary_iarchive) + +int main( int argc, char* argv[] ) +{ + const int a[3] = {1, 2, 3}; + int a1[3] = {4, 5, 6}; + + std::stringstream ss; + { + fast_binary_oarchive pboa(ss); + pboa << a; + } + { + fast_binary_iarchive pbia(ss); + pbia >> a1; + } + return (a[0] != a1[0]) || (a[1] != a1[1]) || (a[2] != a1[2]); +} + + diff --git a/src/boost/libs/serialization/example/demo_gps.hpp b/src/boost/libs/serialization/example/demo_gps.hpp new file mode 100644 index 00000000..1830db3b --- /dev/null +++ b/src/boost/libs/serialization/example/demo_gps.hpp @@ -0,0 +1,284 @@ +#ifndef BOOST_SERIALIZATION_EXAMPLE_DEMO_GPS_HPP +#define BOOST_SERIALIZATION_EXAMPLE_DEMO_GPS_HPP + +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// +// demo_gps.hpp +// +// (C) Copyright 2002-4 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +#include <iomanip> +#include <iostream> +#include <fstream> + +#include <boost/serialization/string.hpp> +#include <boost/serialization/nvp.hpp> +#include <boost/serialization/utility.hpp> +#include <boost/serialization/list.hpp> +#include <boost/serialization/version.hpp> +#include <boost/serialization/assume_abstract.hpp> + +// This illustration models the bus system of a small city. +// This includes, multiple bus stops, bus routes and schedules. +// There are different kinds of stops. Bus stops in general will +// will appear on multiple routes. A schedule will include +// muliple trips on the same route. + +///////////////////////////////////////////////////////////// +// gps coordinate +// +// llustrates serialization for a simple type +// +class gps_position +{ + friend class boost::serialization::access; + friend std::ostream & operator<<(std::ostream &os, const gps_position &gp); + + int degrees; + int minutes; + float seconds; + + template<class Archive> + void serialize(Archive & ar, const unsigned int /* file_version */){ + ar & BOOST_SERIALIZATION_NVP(degrees) + & BOOST_SERIALIZATION_NVP(minutes) + & BOOST_SERIALIZATION_NVP(seconds); + } + +public: + // every serializable class needs a constructor + gps_position(){}; + gps_position(int _d, int _m, float _s) : + degrees(_d), minutes(_m), seconds(_s) + {} +}; + +std::ostream & operator<<(std::ostream &os, const gps_position &gp) +{ + return os << ' ' << gp.degrees << (unsigned char)186 << gp.minutes << '\'' << gp.seconds << '"'; +} + +///////////////////////////////////////////////////////////// +// One bus stop +// +// illustrates serialization of serializable members +// + +class bus_stop +{ + friend class boost::serialization::access; + virtual std::string description() const = 0; + gps_position latitude; + gps_position longitude; + + template<class Archive> + void serialize(Archive &ar, const unsigned int version) + { + ar & BOOST_SERIALIZATION_NVP(latitude); + ar & BOOST_SERIALIZATION_NVP(longitude); + } + +protected: + bus_stop(const gps_position & _lat, const gps_position & _long) : + latitude(_lat), longitude(_long) + {} +public: + bus_stop(){} + friend std::ostream & operator<<(std::ostream &os, const bus_stop &gp); + virtual ~bus_stop(){} +}; + +BOOST_SERIALIZATION_ASSUME_ABSTRACT(bus_stop) + +std::ostream & operator<<(std::ostream &os, const bus_stop &bs) +{ + return os << bs.latitude << bs.longitude << ' ' << bs.description(); +} + +///////////////////////////////////////////////////////////// +// Several kinds of bus stops +// +// illustrates serialization of derived types +// +class bus_stop_corner : public bus_stop +{ + friend class boost::serialization::access; + std::string street1; + std::string street2; + virtual std::string description() const + { + return street1 + " and " + street2; + } + template<class Archive> + void serialize(Archive &ar, const unsigned int version) + { + // save/load base class information + ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(bus_stop); + ar & BOOST_SERIALIZATION_NVP(street1); + ar & BOOST_SERIALIZATION_NVP(street2); + } +public: + bus_stop_corner(){} + bus_stop_corner(const gps_position & _lat, const gps_position & _long, + const std::string & _s1, const std::string & _s2 + ) : + bus_stop(_lat, _long), street1(_s1), street2(_s2) + { + } +}; + +class bus_stop_destination : public bus_stop +{ + friend class boost::serialization::access; + std::string name; + virtual std::string description() const + { + return name; + } + template<class Archive> + void serialize(Archive &ar, const unsigned int version) + { + ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(bus_stop) + & BOOST_SERIALIZATION_NVP(name); + } +public: + bus_stop_destination(){} + bus_stop_destination( + const gps_position & _lat, const gps_position & _long, const std::string & _name + ) : + bus_stop(_lat, _long), name(_name) + { + } +}; + +///////////////////////////////////////////////////////////// +// a bus route is a collection of bus stops +// +// illustrates serialization of STL collection templates. +// +// illustrates serialzation of polymorphic pointer (bus stop *); +// +// illustrates storage and recovery of shared pointers is correct +// and efficient. That is objects pointed to by more than one +// pointer are stored only once. In such cases only one such +// object is restored and pointers are restored to point to it +// +class bus_route +{ + friend class boost::serialization::access; + friend std::ostream & operator<<(std::ostream &os, const bus_route &br); + typedef bus_stop * bus_stop_pointer; + std::list<bus_stop_pointer> stops; + template<class Archive> + void serialize(Archive &ar, const unsigned int version) + { + // in this program, these classes are never serialized directly but rather + // through a pointer to the base class bus_stop. So we need a way to be + // sure that the archive contains information about these derived classes. + //ar.template register_type<bus_stop_corner>(); + ar.register_type(static_cast<bus_stop_corner *>(NULL)); + //ar.template register_type<bus_stop_destination>(); + ar.register_type(static_cast<bus_stop_destination *>(NULL)); + // serialization of stl collections is already defined + // in the header + ar & BOOST_SERIALIZATION_NVP(stops); + } +public: + bus_route(){} + void append(bus_stop *_bs) + { + stops.insert(stops.end(), _bs); + } +}; +std::ostream & operator<<(std::ostream &os, const bus_route &br) +{ + std::list<bus_stop *>::const_iterator it; + // note: we're displaying the pointer to permit verification + // that duplicated pointers are properly restored. + for(it = br.stops.begin(); it != br.stops.end(); it++){ + os << '\n' << std::hex << "0x" << *it << std::dec << ' ' << **it; + } + return os; +} + +///////////////////////////////////////////////////////////// +// a bus schedule is a collection of routes each with a starting time +// +// Illustrates serialization of STL objects(pair) in a non-intrusive way. +// See definition of operator<< <pair<F, S> >(ar, pair) +// +// illustrates nesting of serializable classes +// +// illustrates use of version number to automatically grandfather older +// versions of the same class. + +class bus_schedule +{ + friend class boost::serialization::access; + friend std::ostream & operator<<(std::ostream &os, const bus_schedule &bs); + template<class Archive> + void serialize(Archive &ar, const unsigned int version) + { + ar & BOOST_SERIALIZATION_NVP(schedule); + } + // note: this structure was made public. because the friend declarations + // didn't seem to work as expected. +public: + struct trip_info + { + template<class Archive> + void serialize(Archive &ar, const unsigned int file_version) + { + // in versions 2 or later + if(file_version >= 2) + // read the drivers name + ar & BOOST_SERIALIZATION_NVP(driver); + // all versions have the follwing info + ar & BOOST_SERIALIZATION_NVP(hour) + & BOOST_SERIALIZATION_NVP(minute); + } + + // starting time + int hour; + int minute; + // only after system shipped was the driver's name added to the class + std::string driver; + + trip_info(){} + trip_info(int _h, int _m, const std::string &_d) : + hour(_h), minute(_m), driver(_d) + {} + ~trip_info(){ + } + }; +// friend std::ostream & operator<<(std::ostream &os, const trip_info &ti); +private: + std::list<std::pair<trip_info, bus_route *> > schedule; +public: + void append(const std::string &_d, int _h, int _m, bus_route *_br) + { + schedule.insert(schedule.end(), std::make_pair(trip_info(_h, _m, _d), _br)); + } + bus_schedule(){} +}; + +BOOST_CLASS_VERSION(bus_schedule::trip_info, 3) +BOOST_CLASS_VERSION(bus_schedule, 2) + +std::ostream & operator<<(std::ostream &os, const bus_schedule::trip_info &ti) +{ + return os << '\n' << ti.hour << ':' << ti.minute << ' ' << ti.driver << ' '; +} +std::ostream & operator<<(std::ostream &os, const bus_schedule &bs) +{ + std::list<std::pair<bus_schedule::trip_info, bus_route *> >::const_iterator it; + for(it = bs.schedule.begin(); it != bs.schedule.end(); it++){ + os << it->first << *(it->second); + } + return os; +} + +#endif // BOOST_SERIALIZATION_EXAMPLE_DEMO_GPS_HPP diff --git a/src/boost/libs/serialization/example/demo_log.cpp b/src/boost/libs/serialization/example/demo_log.cpp new file mode 100644 index 00000000..eef40ec8 --- /dev/null +++ b/src/boost/libs/serialization/example/demo_log.cpp @@ -0,0 +1,76 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// +// demo_log.cpp +// +// (C) Copyright 2009 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +#include <iostream> +#include <cstdio> + +#include "demo_gps.hpp" +#include "log_archive.hpp" + +int main(int argc, char *argv[]){ + // make the schedule + bus_schedule schedule; + + // fill in the data + // make a few stops + bus_stop *bs0 = new bus_stop_corner( + gps_position(34, 135, 52.560f), + gps_position(134, 22, 78.30f), + "24th Street", "10th Avenue" + ); + bus_stop *bs1 = new bus_stop_corner( + gps_position(35, 137, 23.456f), + gps_position(133, 35, 54.12f), + "State street", "Cathedral Vista Lane" + ); + bus_stop *bs2 = new bus_stop_destination( + gps_position(35, 136, 15.456f), + gps_position(133, 32, 15.300f), + "White House" + ); + bus_stop *bs3 = new bus_stop_destination( + gps_position(35, 134, 48.789f), + gps_position(133, 32, 16.230f), + "Lincoln Memorial" + ); + + // make a routes + bus_route route0; + route0.append(bs0); + route0.append(bs1); + route0.append(bs2); + + // add trips to schedule + schedule.append("bob", 6, 24, &route0); + schedule.append("bob", 9, 57, &route0); + schedule.append("alice", 11, 02, &route0); + + // make aother routes + bus_route route1; + route1.append(bs3); + route1.append(bs2); + route1.append(bs1); + + // add trips to schedule + schedule.append("ted", 7, 17, &route1); + schedule.append("ted", 9, 38, &route1); + schedule.append("alice", 11, 47, &route1); + + // display the complete schedule + log_archive oa(std::cout); + oa << BOOST_SERIALIZATION_NVP(schedule); + oa << schedule; + + delete bs0; + delete bs1; + delete bs2; + delete bs3; + return 0; +} + diff --git a/src/boost/libs/serialization/example/demo_output.txt b/src/boost/libs/serialization/example/demo_output.txt new file mode 100644 index 00000000..306bdbdc --- /dev/null +++ b/src/boost/libs/serialization/example/demo_output.txt @@ -0,0 +1,51 @@ +original schedule +6:24 bob +0x003265C8 34º135'52.56" 134º22'78.3" 24th Street and 10th Avenue +0x00326648 35º137'23.456" 133º35'54.12" State street and Cathedral Vista Lane +0x00326768 35º136'15.456" 133º32'15.3" White House +9:57 bob +0x003265C8 34º135'52.56" 134º22'78.3" 24th Street and 10th Avenue +0x00326648 35º137'23.456" 133º35'54.12" State street and Cathedral Vista Lane +0x00326768 35º136'15.456" 133º32'15.3" White House +11:2 alice +0x003265C8 34º135'52.56" 134º22'78.3" 24th Street and 10th Avenue +0x00326648 35º137'23.456" 133º35'54.12" State street and Cathedral Vista Lane +0x00326768 35º136'15.456" 133º32'15.3" White House +7:17 ted +0x003267D0 35º134'48.789" 133º32'16.23" Lincoln Memorial +0x00326768 35º136'15.456" 133º32'15.3" White House +0x00326648 35º137'23.456" 133º35'54.12" State street and Cathedral Vista Lane +9:38 ted +0x003267D0 35º134'48.789" 133º32'16.23" Lincoln Memorial +0x00326768 35º136'15.456" 133º32'15.3" White House +0x00326648 35º137'23.456" 133º35'54.12" State street and Cathedral Vista Lane +11:47 alice +0x003267D0 35º134'48.789" 133º32'16.23" Lincoln Memorial +0x00326768 35º136'15.456" 133º32'15.3" White House +0x00326648 35º137'23.456" 133º35'54.12" State street and Cathedral Vista Lane +restored schedule +6:24 +0x0032A2F8 34º135'52.56" 134º22'78.3" 24th Street and 10th Avenue +0x0032A508 35º137'23.456" 133º35'54.12" State street and Cathedral Vista Lane +0x0032A628 35º136'15.456" 133º32'15.3" White House +9:57 +0x0032A2F8 34º135'52.56" 134º22'78.3" 24th Street and 10th Avenue +0x0032A508 35º137'23.456" 133º35'54.12" State street and Cathedral Vista Lane +0x0032A628 35º136'15.456" 133º32'15.3" White House +11:2 +0x0032A2F8 34º135'52.56" 134º22'78.3" 24th Street and 10th Avenue +0x0032A508 35º137'23.456" 133º35'54.12" State street and Cathedral Vista Lane +0x0032A628 35º136'15.456" 133º32'15.3" White House +7:17 +0x0032A8C0 35º134'48.789" 133º32'16.23" Lincoln Memorial +0x0032A628 35º136'15.456" 133º32'15.3" White House +0x0032A508 35º137'23.456" 133º35'54.12" State street and Cathedral Vista Lane +9:38 +0x0032A8C0 35º134'48.789" 133º32'16.23" Lincoln Memorial +0x0032A628 35º136'15.456" 133º32'15.3" White House +0x0032A508 35º137'23.456" 133º35'54.12" State street and Cathedral Vista Lane +11:47 +0x0032A8C0 35º134'48.789" 133º32'16.23" Lincoln Memorial +0x0032A628 35º136'15.456" 133º32'15.3" White House +0x0032A508 35º137'23.456" 133º35'54.12" State street and Cathedral Vista Lane +*** No errors detected diff --git a/src/boost/libs/serialization/example/demo_pimpl.cpp b/src/boost/libs/serialization/example/demo_pimpl.cpp new file mode 100644 index 00000000..2d5446d3 --- /dev/null +++ b/src/boost/libs/serialization/example/demo_pimpl.cpp @@ -0,0 +1,34 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// demo_pimpl.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <sstream> + +#include <boost/archive/text_iarchive.hpp> +#include <boost/archive/text_oarchive.hpp> + +#include "demo_pimpl_A.hpp" + +int main(int argc, char* argv[]) +{ + std::stringstream ss; + + const A a; + { + boost::archive::text_oarchive oa(ss); + oa << a; + } + A a1; + { + boost::archive::text_iarchive ia(ss); + ia >> a1; + } + return 0; +} + diff --git a/src/boost/libs/serialization/example/demo_pimpl_A.cpp b/src/boost/libs/serialization/example/demo_pimpl_A.cpp new file mode 100644 index 00000000..455b71ec --- /dev/null +++ b/src/boost/libs/serialization/example/demo_pimpl_A.cpp @@ -0,0 +1,45 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// demo_pimpl_A.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +#include <boost/archive/text_iarchive.hpp> +#include <boost/archive/text_oarchive.hpp> + +#include "demo_pimpl_A.hpp" + +// "hidden" definition of class B +struct B { + int b; + template<class Archive> + void serialize(Archive & ar, const unsigned int /* file_version */){ + ar & b; + } +}; + +A::A() : + pimpl(new B) +{} +A::~A(){ + delete pimpl; +} +// now we can define the serialization for class A +template<class Archive> +void A::serialize(Archive & ar, const unsigned int /* file_version */){ + ar & pimpl; +} + +// without the explicit instantiations below, the program will +// fail to link for lack of instantiantiation of the above function +// note: the following failed to fix link errors for vc 7.0 ! +template void A::serialize<boost::archive::text_iarchive>( + boost::archive::text_iarchive & ar, + const unsigned int file_version +); +template void A::serialize<boost::archive::text_oarchive>( + boost::archive::text_oarchive & ar, + const unsigned int file_version +); diff --git a/src/boost/libs/serialization/example/demo_pimpl_A.hpp b/src/boost/libs/serialization/example/demo_pimpl_A.hpp new file mode 100644 index 00000000..8697de8d --- /dev/null +++ b/src/boost/libs/serialization/example/demo_pimpl_A.hpp @@ -0,0 +1,24 @@ +#ifndef BOOST_SERIALIZATION_EXAMPLE_DEMO_PIMPL_A_HPP +#define BOOST_SERIALIZATION_EXAMPLE_DEMO_PIMPL_A_HPP + +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// demo_pimpl_A.hpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// class whose declaration is hidden by a pointer +struct B; + +struct A { + // class a contains a pointer to a "hidden" declaration + B *pimpl; + template<class Archive> + void serialize(Archive & ar, const unsigned int file_version); + A(); + ~A(); +}; + +#endif // BOOST_SERIALIZATION_EXAMPLE_DEMO_PIMPL_A_HPP diff --git a/src/boost/libs/serialization/example/demo_polymorphic.cpp b/src/boost/libs/serialization/example/demo_polymorphic.cpp new file mode 100644 index 00000000..3c91745a --- /dev/null +++ b/src/boost/libs/serialization/example/demo_polymorphic.cpp @@ -0,0 +1,65 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// demo_polymorphic.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <sstream> + +#include <boost/archive/polymorphic_text_iarchive.hpp> +#include <boost/archive/polymorphic_text_oarchive.hpp> + +#include <boost/archive/polymorphic_binary_iarchive.hpp> +#include <boost/archive/polymorphic_binary_oarchive.hpp> + +#include "demo_polymorphic_A.hpp" + +int main(int argc, char* argv[]) +{ + const A a; + A a1; + { + // test with a text archive + std::stringstream ss; + { + // instantiate archive which inhertis polymorphic interface + // and the normal text archive implementation + boost::archive::polymorphic_text_oarchive oa(ss); + boost::archive::polymorphic_oarchive & oa_interface = oa; + // we can just just the interface for saving + oa_interface << a; + } + { + // or we can use the implementation directly + boost::archive::polymorphic_text_iarchive ia(ss); + ia >> a1; + } + } + if(! (a == a1)) + return 1; + { + //test with a binary archive + std::stringstream ss; + { + // instantiate archive which inhertis polymorphic interface + // and the normal binary archive implementation + boost::archive::polymorphic_binary_oarchive oa(ss); + oa << a; + } + { + // see above + boost::archive::polymorphic_binary_iarchive ia(ss); + boost::archive::polymorphic_iarchive & ia_interface = ia; + // use just the polymorphic interface for loading. + ia_interface >> a1; + } + } + if(! (a == a1)) + return 1; + return 0; +} + diff --git a/src/boost/libs/serialization/example/demo_polymorphic_A.cpp b/src/boost/libs/serialization/example/demo_polymorphic_A.cpp new file mode 100644 index 00000000..c32d4a13 --- /dev/null +++ b/src/boost/libs/serialization/example/demo_polymorphic_A.cpp @@ -0,0 +1,26 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// demo_polymorphic_A.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + + +#include <boost/archive/polymorphic_iarchive.hpp> +#include <boost/archive/polymorphic_oarchive.hpp> + +#include "demo_polymorphic_A.hpp" + +// explicitly instantiate templates for polymorphic archives +// used by this demo. +template +void A::serialize<boost::archive::polymorphic_iarchive>( + boost::archive::polymorphic_iarchive &, + const unsigned int +); +template +void A::serialize<boost::archive::polymorphic_oarchive>( + boost::archive::polymorphic_oarchive &, + const unsigned int +); diff --git a/src/boost/libs/serialization/example/demo_polymorphic_A.hpp b/src/boost/libs/serialization/example/demo_polymorphic_A.hpp new file mode 100644 index 00000000..17f9758f --- /dev/null +++ b/src/boost/libs/serialization/example/demo_polymorphic_A.hpp @@ -0,0 +1,39 @@ +#ifndef BOOST_SERIALIZATION_EXAMPLE_DEMO_POLYMORPHIC_A_HPP +#define BOOST_SERIALIZATION_EXAMPLE_DEMO_POLYMORPHIC_A_HPP + +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// demo_polymorphic_A.hpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +namespace boost { +namespace archive { + +class polymorphic_iarchive; +class polymorphic_oarchive; + +} // namespace archive +} // namespace boost + +struct A { + // class a contains a pointer to a "hidden" declaration + template<class Archive> + void serialize( + Archive & ar, + const unsigned int file_version + ){ + ar & data; + } + int data; + bool operator==(const A & rhs) const { + return data == rhs.data; + } + A() : + data(0) + {} +}; + +#endif // BOOST_SERIALIZATION_EXAMPLE_DEMO_POLYMORPHIC_A_HPP diff --git a/src/boost/libs/serialization/example/demo_portable_archive.cpp b/src/boost/libs/serialization/example/demo_portable_archive.cpp new file mode 100644 index 00000000..6d9fb2be --- /dev/null +++ b/src/boost/libs/serialization/example/demo_portable_archive.cpp @@ -0,0 +1,104 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// +// demo_portable_archive.cpp +// +// (C) Copyright 2002-4 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +// note:: this example can only be built with the static library +// (at least with MSVC - due to conflicts related to import of library +// code and instantiation of templates. +#include <sstream> + +#include "portable_binary_oarchive.hpp" +#include "portable_binary_iarchive.hpp" + +#include <cstdlib> +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ using ::rand; } +#endif + +class A +{ + friend class boost::serialization::access; + char c; + A *pa; + int i; + int i2; // special tricky case to check sign extension + unsigned int ui; + long l; + unsigned long ul; + template<class Archive> + void serialize(Archive & ar, const unsigned int /* version */){ + ar & c & i & i2 & ui & l & ul ; + } +public: + bool operator==(const A & rhs) const { + return + c == rhs.c + && i == rhs.i + && i2 == rhs.i2 + && ui == rhs.ui + && l == rhs.l + && ul == rhs.ul + ; + } + A() : + c(0xFF & std::rand()), + pa(0), + i(std::rand()), + i2(0x80), + ui(std::rand()), + l(std::rand() * std::rand()), + ul(std::rand()) + {} +}; + +int main( int /* argc */, char* /* argv */[] ) +{ + const A a; + A a1; + + std::stringstream ss; + { + portable_binary_oarchive pboa(ss); + pboa << a; + } + { + portable_binary_iarchive pbia(ss); + pbia >> a1; + } + if(! (a == a1)) + return 1; + + ss.clear(); + { + portable_binary_oarchive pboa(ss, endian_big); + pboa << a; + } + { + portable_binary_iarchive pbia(ss, endian_big); + pbia >> a1; + } + if(! (a == a1)) + return 1; + + ss.clear(); + { + portable_binary_oarchive pboa(ss, endian_big); + pboa << a; + } + { + portable_binary_iarchive pbia(ss, endian_big); + pbia >> a1; + } + + return !(a == a1); +} + + diff --git a/src/boost/libs/serialization/example/demo_save.xml b/src/boost/libs/serialization/example/demo_save.xml new file mode 100644 index 00000000..c5a28c8e --- /dev/null +++ b/src/boost/libs/serialization/example/demo_save.xml @@ -0,0 +1,129 @@ +<?xml version="1.0" encoding="UTF-8" standalone="yes" ?> +<!DOCTYPE boost_serialization> +<boost_serialization signature="serialization::archive" version="3"> +<s class_id="0" tracking_level="0" version="2"> + <schedule class_id="1" tracking_level="0"> + <count>6</count> + <item class_id="2" tracking_level="0"> + <first class_id="3" tracking_level="0" version="3"> + <driver>bob</driver> + <hour>6</hour> + <minute>24</minute> + </first> + <second class_id="4" tracking_level="1" object_id="_0"> + <stops class_id="7" tracking_level="0"> + <count>3</count> + <item class_id="5" tracking_level="1" object_id="_1"> + <bus_stop class_id="8" tracking_level="0"> + <latitude class_id="9" tracking_level="0"> + <degrees>34</degrees> + <minutes>135</minutes> + <seconds>52.560001</seconds> + </latitude> + <longitude> + <degrees>134</degrees> + <minutes>22</minutes> + <seconds>78.300003</seconds> + </longitude> + </bus_stop> + <street1>24th Street</street1> + <street2>10th Avenue</street2> + </item> + <item class_id_reference="5" object_id="_2"> + <bus_stop> + <latitude> + <degrees>35</degrees> + <minutes>137</minutes> + <seconds>23.455999</seconds> + </latitude> + <longitude> + <degrees>133</degrees> + <minutes>35</minutes> + <seconds>54.119999</seconds> + </longitude> + </bus_stop> + <street1>State street</street1> + <street2>Cathedral Vista Lane</street2> + </item> + <item class_id="6" tracking_level="1" object_id="_3"> + <bus_stop> + <latitude> + <degrees>35</degrees> + <minutes>136</minutes> + <seconds>15.456</seconds> + </latitude> + <longitude> + <degrees>133</degrees> + <minutes>32</minutes> + <seconds>15.3</seconds> + </longitude> + </bus_stop> + <name>White House</name> + </item> + </stops> + </second> + </item> + <item> + <first> + <driver>bob</driver> + <hour>9</hour> + <minute>57</minute> + </first> + <second class_id_reference="4" object_id_reference="_0"></second> + </item> + <item> + <first> + <driver>alice</driver> + <hour>11</hour> + <minute>2</minute> + </first> + <second class_id_reference="4" object_id_reference="_0"></second> + </item> + <item> + <first> + <driver>ted</driver> + <hour>7</hour> + <minute>17</minute> + </first> + <second class_id_reference="4" object_id="_4"> + <stops> + <count>3</count> + <item class_id_reference="6" object_id="_5"> + <bus_stop> + <latitude> + <degrees>35</degrees> + <minutes>134</minutes> + <seconds>48.789001</seconds> + </latitude> + <longitude> + <degrees>133</degrees> + <minutes>32</minutes> + <seconds>16.23</seconds> + </longitude> + </bus_stop> + <name>Lincoln Memorial</name> + </item> + <item class_id_reference="6" object_id_reference="_3"></item> + <item class_id_reference="5" object_id_reference="_2"></item> + </stops> + </second> + </item> + <item> + <first> + <driver>ted</driver> + <hour>9</hour> + <minute>38</minute> + </first> + <second class_id_reference="4" object_id_reference="_4"></second> + </item> + <item> + <first> + <driver>alice</driver> + <hour>11</hour> + <minute>47</minute> + </first> + <second class_id_reference="4" object_id_reference="_4"></second> + </item> + </schedule> +</s> +</boost_serialization> diff --git a/src/boost/libs/serialization/example/demo_shared_ptr.cpp b/src/boost/libs/serialization/example/demo_shared_ptr.cpp new file mode 100644 index 00000000..fb347a7c --- /dev/null +++ b/src/boost/libs/serialization/example/demo_shared_ptr.cpp @@ -0,0 +1,164 @@ +// demo_shared_ptr.cpp : demonstrates adding serialization to a template + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . Polymorphic +// derived pointer example by David Tonge. + +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) +// +// See http://www.boost.org for updates, documentation, and revision history. + +#include <iomanip> +#include <iostream> +#include <cstddef> // NULL +#include <fstream> +#include <string> + +#include <cstdio> // remove +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include <boost/archive/text_oarchive.hpp> +#include <boost/archive/text_iarchive.hpp> +#include <boost/archive/tmpdir.hpp> + +#include <boost/serialization/shared_ptr.hpp> + +/////////////////////////// +// test shared_ptr serialization +class A +{ +private: + friend class boost::serialization::access; + int x; + template<class Archive> + void serialize(Archive & ar, const unsigned int /* file_version */){ + ar & x; + } +public: + static int count; + A(){++count;} // default constructor + virtual ~A(){--count;} // default destructor +}; + +BOOST_SERIALIZATION_SHARED_PTR(A) + +///////////////// +// ADDITION BY DT +class B : public A +{ +private: + friend class boost::serialization::access; + int x; + template<class Archive> + void serialize(Archive & ar, const unsigned int /* file_version */){ + ar & boost::serialization::base_object<A>(*this); + } +public: + static int count; + B() : A() {}; + virtual ~B() {}; +}; + +BOOST_SERIALIZATION_SHARED_PTR(B) + +///////////////// + +int A::count = 0; + +void display(boost::shared_ptr<A> &spa, boost::shared_ptr<A> &spa1) +{ + std::cout << "a = 0x" << std::hex << spa.get() << " "; + if (spa.get()) std::cout << "is a " << typeid(*(spa.get())).name() << "* "; + std::cout << "use count = " << std::dec << spa.use_count() << std::endl; + std::cout << "a1 = 0x" << std::hex << spa1.get() << " "; + if (spa1.get()) std::cout << "is a " << typeid(*(spa1.get())).name() << "* "; + std::cout << "use count = " << std::dec << spa1.use_count() << std::endl; + std::cout << "unique element count = " << A::count << std::endl; +} + +int main(int /* argc */, char * /*argv*/[]) +{ + std::string filename(boost::archive::tmpdir()); + filename += "/testfile"; + + // create a new shared pointer to ta new object of type A + boost::shared_ptr<A> spa(new A); + boost::shared_ptr<A> spa1; + spa1 = spa; + display(spa, spa1); + // serialize it + { + std::ofstream ofs(filename.c_str()); + boost::archive::text_oarchive oa(ofs); + oa << spa; + oa << spa1; + } + // reset the shared pointer to NULL + // thereby destroying the object of type A + spa.reset(); + spa1.reset(); + display(spa, spa1); + // restore state to one equivalent to the original + // creating a new type A object + { + // open the archive + std::ifstream ifs(filename.c_str()); + boost::archive::text_iarchive ia(ifs); + + // restore the schedule from the archive + ia >> spa; + ia >> spa1; + } + display(spa, spa1); + spa.reset(); + spa1.reset(); + + std::cout << std::endl; + std::cout << std::endl; + std::cout << "New tests" << std::endl; + + ///////////////// + // ADDITION BY DT + // create a new shared pointer to ta new object of type A + spa = boost::shared_ptr<A>(new B); + spa1 = spa; + display(spa, spa1); + // serialize it + { + std::ofstream ofs(filename.c_str()); + boost::archive::text_oarchive oa(ofs); + oa.register_type(static_cast<B *>(NULL)); + oa << spa; + oa << spa1; + } + // reset the shared pointer to NULL + // thereby destroying the object of type B + spa.reset(); + spa1.reset(); + display(spa, spa1); + // restore state to one equivalent to the original + // creating a new type B object + { + // open the archive + std::ifstream ifs(filename.c_str()); + boost::archive::text_iarchive ia(ifs); + + // restore the schedule from the archive + ia.register_type(static_cast<B *>(NULL)); + ia >> spa; + ia >> spa1; + } + display(spa, spa1); + /////////////// + std::remove(filename.c_str()); + + // obj of type A gets destroyed + // as smart_ptr goes out of scope + return 0; +} diff --git a/src/boost/libs/serialization/example/demo_simple_log.cpp b/src/boost/libs/serialization/example/demo_simple_log.cpp new file mode 100644 index 00000000..da80b5a5 --- /dev/null +++ b/src/boost/libs/serialization/example/demo_simple_log.cpp @@ -0,0 +1,75 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// +// demo_log.cpp +// +// (C) Copyright 2009 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +#include <iostream> +#include <cstdio> + +#include "demo_gps.hpp" +#include "simple_log_archive.hpp" + +int main(int argc, char *argv[]) +{ + // make the schedule + bus_schedule schedule; + + // fill in the data + // make a few stops + bus_stop *bs0 = new bus_stop_corner( + gps_position(34, 135, 52.560f), + gps_position(134, 22, 78.30f), + "24th Street", "10th Avenue" + ); + bus_stop *bs1 = new bus_stop_corner( + gps_position(35, 137, 23.456f), + gps_position(133, 35, 54.12f), + "State street", "Cathedral Vista Lane" + ); + bus_stop *bs2 = new bus_stop_destination( + gps_position(35, 136, 15.456f), + gps_position(133, 32, 15.300f), + "White House" + ); + bus_stop *bs3 = new bus_stop_destination( + gps_position(35, 134, 48.789f), + gps_position(133, 32, 16.230f), + "Lincoln Memorial" + ); + + // make a routes + bus_route route0; + route0.append(bs0); + route0.append(bs1); + route0.append(bs2); + + // add trips to schedule + schedule.append("bob", 6, 24, &route0); + schedule.append("bob", 9, 57, &route0); + schedule.append("alice", 11, 02, &route0); + + // make aother routes + bus_route route1; + route1.append(bs3); + route1.append(bs2); + route1.append(bs1); + + // add trips to schedule + schedule.append("ted", 7, 17, &route1); + schedule.append("ted", 9, 38, &route1); + schedule.append("alice", 11, 47, &route1); + + // display the complete schedule + simple_log_archive log(std::cout); + log << schedule; + + delete bs0; + delete bs1; + delete bs2; + delete bs3; + return 0; +} diff --git a/src/boost/libs/serialization/example/demo_trivial_archive.cpp b/src/boost/libs/serialization/example/demo_trivial_archive.cpp new file mode 100644 index 00000000..21be5963 --- /dev/null +++ b/src/boost/libs/serialization/example/demo_trivial_archive.cpp @@ -0,0 +1,94 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// +// demo_trivial_archive.cpp +// +// (C) Copyright 2009 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +#include <cstddef> // std::size_t +#include <boost/mpl/bool.hpp> + +///////////////////////////////////////////////////////////////////////// +// class trivial_oarchive +class trivial_oarchive { + +public: + ////////////////////////////////////////////////////////// + // public interface used by programs that use the + // serialization library + typedef boost::mpl::bool_<true> is_saving; + typedef boost::mpl::bool_<false> is_loading; + template<class T> void register_type(){} + template<class T> trivial_oarchive & operator<<(const T & t){ + return *this; + } + template<class T> trivial_oarchive & operator&(const T & t){ + return *this << t; + } + void save_binary(void *address, std::size_t count){}; +}; + +#include "demo_gps.hpp" + +int main(int argc, char *argv[]) +{ + // make the schedule + bus_schedule schedule; + + // fill in the data + // make a few stops + bus_stop *bs0 = new bus_stop_corner( + gps_position(34, 135, 52.560f), + gps_position(134, 22, 78.30f), + "24th Street", "10th Avenue" + ); + bus_stop *bs1 = new bus_stop_corner( + gps_position(35, 137, 23.456f), + gps_position(133, 35, 54.12f), + "State street", "Cathedral Vista Lane" + ); + bus_stop *bs2 = new bus_stop_destination( + gps_position(35, 136, 15.456f), + gps_position(133, 32, 15.300f), + "White House" + ); + bus_stop *bs3 = new bus_stop_destination( + gps_position(35, 134, 48.789f), + gps_position(133, 32, 16.230f), + "Lincoln Memorial" + ); + + // make a routes + bus_route route0; + route0.append(bs0); + route0.append(bs1); + route0.append(bs2); + + // add trips to schedule + schedule.append("bob", 6, 24, &route0); + schedule.append("bob", 9, 57, &route0); + schedule.append("alice", 11, 02, &route0); + + // make aother routes + bus_route route1; + route1.append(bs3); + route1.append(bs2); + route1.append(bs1); + + // add trips to schedule + schedule.append("ted", 7, 17, &route1); + schedule.append("ted", 9, 38, &route1); + schedule.append("alice", 11, 47, &route1); + + // display the complete schedule + trivial_oarchive ta; + ta << schedule; + + delete bs0; + delete bs1; + delete bs2; + delete bs3; + return 0; +} diff --git a/src/boost/libs/serialization/example/demo_xml.cpp b/src/boost/libs/serialization/example/demo_xml.cpp new file mode 100644 index 00000000..c9524aef --- /dev/null +++ b/src/boost/libs/serialization/example/demo_xml.cpp @@ -0,0 +1,127 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// +// demo_xml.cpp +// +// (C) Copyright 2002-4 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +#include <iomanip> +#include <iostream> +#include <fstream> +#include <string> + +#include <cstdio> // remove +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include <boost/archive/tmpdir.hpp> +#include <boost/archive/xml_iarchive.hpp> +#include <boost/archive/xml_oarchive.hpp> + +#include "demo_gps.hpp" + +void save_schedule(const bus_schedule &s, const char * filename){ + // make an archive + std::ofstream ofs(filename); + assert(ofs.good()); + boost::archive::xml_oarchive oa(ofs); + oa << BOOST_SERIALIZATION_NVP(s); +} + +void +restore_schedule(bus_schedule &s, const char * filename) +{ + // open the archive + std::ifstream ifs(filename); + assert(ifs.good()); + boost::archive::xml_iarchive ia(ifs); + + // restore the schedule from the archive + ia >> BOOST_SERIALIZATION_NVP(s); +} + +int main(int argc, char *argv[]) +{ + // make the schedule + bus_schedule original_schedule; + + // fill in the data + // make a few stops + bus_stop *bs0 = new bus_stop_corner( + gps_position(34, 135, 52.560f), + gps_position(134, 22, 78.30f), + "24th Street", "10th Avenue" + ); + bus_stop *bs1 = new bus_stop_corner( + gps_position(35, 137, 23.456f), + gps_position(133, 35, 54.12f), + "State street", "Cathedral Vista Lane" + ); + bus_stop *bs2 = new bus_stop_destination( + gps_position(35, 136, 15.456f), + gps_position(133, 32, 15.300f), + "White House" + ); + bus_stop *bs3 = new bus_stop_destination( + gps_position(35, 134, 48.789f), + gps_position(133, 32, 16.230f), + "Lincoln Memorial" + ); + + // make a routes + bus_route route0; + route0.append(bs0); + route0.append(bs1); + route0.append(bs2); + + // add trips to schedule + original_schedule.append("bob", 6, 24, &route0); + original_schedule.append("bob", 9, 57, &route0); + original_schedule.append("alice", 11, 02, &route0); + + // make aother routes + bus_route route1; + route1.append(bs3); + route1.append(bs2); + route1.append(bs1); + + // add trips to schedule + original_schedule.append("ted", 7, 17, &route1); + original_schedule.append("ted", 9, 38, &route1); + original_schedule.append("alice", 11, 47, &route1); + + // display the complete schedule + std::cout << "original schedule"; + std::cout << original_schedule; + + std::string filename(boost::archive::tmpdir()); + filename += "/demo.xml"; + + // save the schedule + save_schedule(original_schedule, filename.c_str()); + + // ... some time later + // make a new schedule + bus_schedule new_schedule; + + restore_schedule(new_schedule, filename.c_str()); + + // and display + std::cout << "\nrestored schedule"; + std::cout << new_schedule; + // should be the same as the old one. (except for the pointer values) + + std::remove(filename.c_str()); + + delete bs0; + delete bs1; + delete bs2; + delete bs3; + return 0; +} diff --git a/src/boost/libs/serialization/example/demo_xml.hpp b/src/boost/libs/serialization/example/demo_xml.hpp new file mode 100644 index 00000000..408412a1 --- /dev/null +++ b/src/boost/libs/serialization/example/demo_xml.hpp @@ -0,0 +1,284 @@ +#ifndef BOOST_SERIALIZATION_EXAMPLE_DEMO_XML_HPP +#define BOOST_SERIALIZATION_EXAMPLE_DEMO_XML_HPP + +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// +// demo_xml.hpp +// +// (C) Copyright 2002-4 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + + +#include <string> +#include <iomanip> +#include <iostream> +#include <fstream> + +#include <boost/serialization/nvp.hpp> +#include <boost/serialization/utility.hpp> +#include <boost/serialization/list.hpp> +#include <boost/serialization/version.hpp> + +// This illustration models the bus system of a small city. +// This includes, multiple bus stops, bus routes and schedules. +// There are different kinds of stops. Bus stops in general will +// will appear on multiple routes. A schedule will include +// muliple trips on the same route. + +///////////////////////////////////////////////////////////// +// gps coordinate +// +// llustrates serialization for a simple type +// +class gps_position +{ + friend class boost::serialization::access; + friend std::ostream & operator<<(std::ostream &os, const gps_position &gp); + + int degrees; + int minutes; + float seconds; + + template<class Archive> + void serialize(Archive & ar, const unsigned int /* file_version */){ + ar & BOOST_SERIALIZATION_NVP(degrees) + & BOOST_SERIALIZATION_NVP(minutes) + & BOOST_SERIALIZATION_NVP(seconds); + } + +public: + // every serializable class needs a constructor + gps_position(){}; + gps_position(int _d, int _m, float _s) : + degrees(_d), minutes(_m), seconds(_s) + {} +}; + +std::ostream & operator<<(std::ostream &os, const gps_position &gp) +{ + return os << ' ' << gp.degrees << (unsigned char)186 << gp.minutes << '\'' << gp.seconds << '"'; +} + +///////////////////////////////////////////////////////////// +// One bus stop +// +// illustrates serialization of serializable members +// + +class bus_stop +{ + friend class boost::serialization::access; + virtual std::string description() const = 0; + gps_position latitude; + gps_position longitude; + + template<class Archive> + void serialize(Archive &ar, const unsigned int version) + { + ar & BOOST_SERIALIZATION_NVP(latitude); + ar & BOOST_SERIALIZATION_NVP(longitude); + } + +protected: + bus_stop(const gps_position & _lat, const gps_position & _long) : + latitude(_lat), longitude(_long) + {} +public: + bus_stop(){} + friend std::ostream & operator<<(std::ostream &os, const bus_stop &gp); + virtual ~bus_stop(){} +}; + +BOOST_IS_ABSTRACT(bus_stop) + +std::ostream & operator<<(std::ostream &os, const bus_stop &bs) +{ + return os << bs.latitude << bs.longitude << ' ' << bs.description(); +} + +///////////////////////////////////////////////////////////// +// Several kinds of bus stops +// +// illustrates serialization of derived types +// +class bus_stop_corner : public bus_stop +{ + friend class boost::serialization::access; + std::string street1; + std::string street2; + virtual std::string description() const + { + return street1 + " and " + street2; + } + template<class Archive> + void serialize(Archive &ar, const unsigned int version) + { + // save/load base class information + ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(bus_stop); + ar & BOOST_SERIALIZATION_NVP(street1); + ar & BOOST_SERIALIZATION_NVP(street2); + } +public: + bus_stop_corner(){} + bus_stop_corner(const gps_position & _lat, const gps_position & _long, + const std::string & _s1, const std::string & _s2 + ) : + bus_stop(_lat, _long), street1(_s1), street2(_s2) + { + } +}; + +class bus_stop_destination : public bus_stop +{ + friend class boost::serialization::access; + std::string name; + virtual std::string description() const + { + return name; + } + template<class Archive> + void serialize(Archive &ar, const unsigned int version) + { + ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(bus_stop) + & BOOST_SERIALIZATION_NVP(name); + } +public: + bus_stop_destination(){} + bus_stop_destination( + const gps_position & _lat, const gps_position & _long, const std::string & _name + ) : + bus_stop(_lat, _long), name(_name) + { + } +}; + +///////////////////////////////////////////////////////////// +// a bus route is a collection of bus stops +// +// illustrates serialization of STL collection templates. +// +// illustrates serialzation of polymorphic pointer (bus stop *); +// +// illustrates storage and recovery of shared pointers is correct +// and efficient. That is objects pointed to by more than one +// pointer are stored only once. In such cases only one such +// object is restored and pointers are restored to point to it +// +class bus_route +{ + friend class boost::serialization::access; + friend std::ostream & operator<<(std::ostream &os, const bus_route &br); + typedef bus_stop * bus_stop_pointer; + std::list<bus_stop_pointer> stops; + template<class Archive> + void serialize(Archive &ar, const unsigned int version) + { + // in this program, these classes are never serialized directly but rather + // through a pointer to the base class bus_stop. So we need a way to be + // sure that the archive contains information about these derived classes. + //ar.template register_type<bus_stop_corner>(); + ar.register_type(static_cast<bus_stop_corner *>(NULL)); + //ar.template register_type<bus_stop_destination>(); + ar.register_type(static_cast<bus_stop_destination *>(NULL)); + // serialization of stl collections is already defined + // in the header + ar & BOOST_SERIALIZATION_NVP(stops); + } +public: + bus_route(){} + void append(bus_stop *_bs) + { + stops.insert(stops.end(), _bs); + } +}; +std::ostream & operator<<(std::ostream &os, const bus_route &br) +{ + std::list<bus_stop *>::const_iterator it; + // note: we're displaying the pointer to permit verification + // that duplicated pointers are properly restored. + for(it = br.stops.begin(); it != br.stops.end(); it++){ + os << '\n' << std::hex << "0x" << *it << std::dec << ' ' << **it; + } + return os; +} + +///////////////////////////////////////////////////////////// +// a bus schedule is a collection of routes each with a starting time +// +// Illustrates serialization of STL objects(pair) in a non-intrusive way. +// See definition of operator<< <pair<F, S> >(ar, pair) +// +// illustrates nesting of serializable classes +// +// illustrates use of version number to automatically grandfather older +// versions of the same class. + +class bus_schedule +{ + friend class boost::serialization::access; + friend std::ostream & operator<<(std::ostream &os, const bus_schedule &bs); + template<class Archive> + void serialize(Archive &ar, const unsigned int version) + { + ar & BOOST_SERIALIZATION_NVP(schedule); + } + // note: this structure was made public. because the friend declarations + // didn't seem to work as expected. +public: + struct trip_info + { + template<class Archive> + void serialize(Archive &ar, const unsigned int file_version) + { + // in versions 2 or later + if(file_version >= 2) + // read the drivers name + ar & BOOST_SERIALIZATION_NVP(driver); + // all versions have the follwing info + ar & BOOST_SERIALIZATION_NVP(hour) + & BOOST_SERIALIZATION_NVP(minute); + } + + // starting time + int hour; + int minute; + // only after system shipped was the driver's name added to the class + std::string driver; + + trip_info(){} + trip_info(int _h, int _m, const std::string &_d) : + hour(_h), minute(_m), driver(_d) + {} + ~trip_info(){ + } + }; +// friend std::ostream & operator<<(std::ostream &os, const trip_info &ti); +private: + std::list<std::pair<trip_info, bus_route *> > schedule; +public: + void append(const std::string &_d, int _h, int _m, bus_route *_br) + { + schedule.insert(schedule.end(), std::make_pair(trip_info(_h, _m, _d), _br)); + } + bus_schedule(){} +}; + +BOOST_CLASS_VERSION(bus_schedule::trip_info, 3) +BOOST_CLASS_VERSION(bus_schedule, 2) + +std::ostream & operator<<(std::ostream &os, const bus_schedule::trip_info &ti) +{ + return os << '\n' << ti.hour << ':' << ti.minute << ' ' << ti.driver << ' '; +} +std::ostream & operator<<(std::ostream &os, const bus_schedule &bs) +{ + std::list<std::pair<bus_schedule::trip_info, bus_route *> >::const_iterator it; + for(it = bs.schedule.begin(); it != bs.schedule.end(); it++){ + os << it->first << *(it->second); + } + return os; +} + +#endif // BOOST_SERIALIZATION_EXAMPLE_DEMO_XML_HPP diff --git a/src/boost/libs/serialization/example/demo_xml_load.cpp b/src/boost/libs/serialization/example/demo_xml_load.cpp new file mode 100644 index 00000000..cd8e03c1 --- /dev/null +++ b/src/boost/libs/serialization/example/demo_xml_load.cpp @@ -0,0 +1,45 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// +// demo_xml_load.cpp +// +// (C) Copyright 2002-4 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +#include <iostream> +#include <string> +#include <boost/archive/tmpdir.hpp> + +#include <boost/archive/xml_iarchive.hpp> + +#include "demo_gps.hpp" + +void +restore_schedule(bus_schedule &s, const char * filename) +{ + // open the archive + std::ifstream ifs(filename); + assert(ifs.good()); + boost::archive::xml_iarchive ia(ifs); + + // restore the schedule from the archive + ia >> BOOST_SERIALIZATION_NVP(s); +} + +int main(int argc, char *argv[]) +{ + // make a new schedule + bus_schedule new_schedule; + + std::string filename(boost::archive::tmpdir()); + filename += "/demo_save.xml"; + + restore_schedule(new_schedule, filename.c_str()); + + // and display + std::cout << "\nrestored schedule"; + std::cout << new_schedule; + + return 0; +} diff --git a/src/boost/libs/serialization/example/demo_xml_save.cpp b/src/boost/libs/serialization/example/demo_xml_save.cpp new file mode 100644 index 00000000..ff03d54a --- /dev/null +++ b/src/boost/libs/serialization/example/demo_xml_save.cpp @@ -0,0 +1,91 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// +// demo_xml_save.cpp +// +// (C) Copyright 2002-4 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +#include <iostream> +#include <string> +#include <boost/archive/tmpdir.hpp> + +#include <boost/archive/xml_oarchive.hpp> + +#include "demo_gps.hpp" + +void save_schedule(const bus_schedule &s, const char * filename){ + // make an archive + std::ofstream ofs(filename); + assert(ofs.good()); + boost::archive::xml_oarchive oa(ofs); + oa << BOOST_SERIALIZATION_NVP(s); +} + +int main(int argc, char *argv[]) +{ + // make the schedule + bus_schedule original_schedule; + + // fill in the data + // make a few stops + bus_stop *bs0 = new bus_stop_corner( + gps_position(34, 135, 52.560f), + gps_position(134, 22, 78.30f), + "24th Street", "10th Avenue" + ); + bus_stop *bs1 = new bus_stop_corner( + gps_position(35, 137, 23.456f), + gps_position(133, 35, 54.12f), + "State street", "Cathedral Vista Lane" + ); + bus_stop *bs2 = new bus_stop_destination( + gps_position(35, 136, 15.456f), + gps_position(133, 32, 15.300f), + "White House" + ); + bus_stop *bs3 = new bus_stop_destination( + gps_position(35, 134, 48.789f), + gps_position(133, 32, 16.230f), + "Lincoln Memorial" + ); + + // make a routes + bus_route route0; + route0.append(bs0); + route0.append(bs1); + route0.append(bs2); + + // add trips to schedule + original_schedule.append("bob", 6, 24, &route0); + original_schedule.append("bob", 9, 57, &route0); + original_schedule.append("alice", 11, 02, &route0); + + // make aother routes + bus_route route1; + route1.append(bs3); + route1.append(bs2); + route1.append(bs1); + + // add trips to schedule + original_schedule.append("ted", 7, 17, &route1); + original_schedule.append("ted", 9, 38, &route1); + original_schedule.append("alice", 11, 47, &route1); + + // display the complete schedule + std::cout << "original schedule"; + std::cout << original_schedule; + + std::string filename(boost::archive::tmpdir()); + filename += "/demo_save.xml"; + + // save the schedule + save_schedule(original_schedule, filename.c_str()); + + delete bs0; + delete bs1; + delete bs2; + delete bs3; + return 0; +} diff --git a/src/boost/libs/serialization/example/demofile.txt b/src/boost/libs/serialization/example/demofile.txt new file mode 100644 index 00000000..59ae12f6 --- /dev/null +++ b/src/boost/libs/serialization/example/demofile.txt @@ -0,0 +1,13 @@ +22 serialization::archive 3 0 2 0 0 6 0 0 0 0 6 24 4 1 0 +0 0 0 3 5 1 0 +1 0 0 0 0 34 135 52.560001 134 22 78.300003 11 24th Street 11 10th Avenue 5 +2 35 137 23.455999 133 35 54.119999 12 State street 20 Cathedral Vista Lane 6 1 0 +3 35 136 15.456 133 32 15.3 11 White House 9 57 4 +0 11 2 4 +0 7 17 4 +4 3 6 +5 35 134 48.789001 133 32 16.23 16 Lincoln Memorial 6 +3 5 +2 9 38 4 +4 11 47 4 +4
\ No newline at end of file diff --git a/src/boost/libs/serialization/example/fix_six.cpp b/src/boost/libs/serialization/example/fix_six.cpp new file mode 100644 index 00000000..f18755f0 --- /dev/null +++ b/src/boost/libs/serialization/example/fix_six.cpp @@ -0,0 +1,37 @@ +#include <fstream> +#include <ios> +#include <iostream> +#include <boost/integer_traits.hpp> +#include <boost/archive/binary_iarchive.hpp> + +void usage(const char * program_name){ + std::cout << "usage:"; + std::cout << program_name << " filename" << std::endl; +} + +int main(int argc, char *argv[]){ + if(argc != 2){ + std::cout << "invalid number of arguments" << std::endl; + usage(argv[0]); + return 1; + } + std::filebuf fb; + fb.open( + argv[1], + std::ios_base::binary | std::ios_base::in | std::ios_base::out + ); + if(!fb.is_open()){ + std::cout << argv[1] << " failed to open" << std::endl; + return 1; + } + boost::archive::binary_iarchive ia(fb); + boost::archive::library_version_type lvt = ia.get_library_version(); + if(boost::archive::library_version_type(6) != lvt){ + std::cout << "library version not equal to six" << std::endl; + return 1; + } + lvt = boost::archive::library_version_type(7); + fb.pubseekpos(26, std::ios_base::out); + fb.sputn(reinterpret_cast<const char *>(& lvt), sizeof(lvt)); + fb.close(); +} diff --git a/src/boost/libs/serialization/example/log_archive.cpp b/src/boost/libs/serialization/example/log_archive.cpp new file mode 100644 index 00000000..86c3631e --- /dev/null +++ b/src/boost/libs/serialization/example/log_archive.cpp @@ -0,0 +1,32 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// log_archive.cpp: + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#if (defined _MSC_VER) && (_MSC_VER == 1200) +# pragma warning (disable : 4786) // too long name, harmless warning +#endif + +//#define BOOST_ARCHIVE_SOURCE +#include "log_archive.hpp" +#include <boost/archive/detail/archive_serializer_map.hpp> + +// explicitly instantiate for this type of xml stream +#include <boost/archive/impl/archive_serializer_map.ipp> +#include <boost/archive/impl/basic_xml_oarchive.ipp> +#include <boost/archive/impl/xml_oarchive_impl.ipp> + +namespace boost { +namespace archive { + +template class detail::archive_serializer_map<log_archive>; +template class basic_xml_oarchive<log_archive> ; +template class xml_oarchive_impl<log_archive> ; + +} // namespace archive +} // namespace boost diff --git a/src/boost/libs/serialization/example/log_archive.hpp b/src/boost/libs/serialization/example/log_archive.hpp new file mode 100644 index 00000000..039f0b3e --- /dev/null +++ b/src/boost/libs/serialization/example/log_archive.hpp @@ -0,0 +1,81 @@ +#ifndef LOG_ARCHIVE_HPP +#define LOG_ARCHIVE_HPP + +// MS compatible compilers support #pragma once +#if defined(_MSC_VER) +# pragma once +#endif + +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// log_archive.hpp + +// (C) Copyright 2010 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <boost/archive/xml_oarchive.hpp> + +namespace boost { + namespace archive { + namespace detail { + template<class Archive> class interface_oarchive; + } // namespace detail + } // namespace archive +} // boost + +///////////////////////////////////////////////////////////////////////// +// log data to an output stream. This illustrates a simpler implemenation +// of text output which is useful for getting a formatted display of +// any serializable class. Intended to be useful as a debugging aid. +class log_archive : + /* protected ? */ + public boost::archive::xml_oarchive_impl<log_archive> +{ + typedef boost::archive::xml_oarchive_impl<log_archive> base; + // give serialization implementation access to this clas + friend class boost::archive::detail::interface_oarchive<log_archive>; + friend class boost::archive::basic_xml_oarchive<log_archive>; + friend class boost::archive::save_access; + + ///////////////////////////////////////////////////////////////////// + // Override functions defined in basic_xml_oarchive + + // Anything not an attribute and not a name-value pair is an + // error and should be trapped here. + template<class T> + void save_override(T & t){ + // make it a name-value pair and pass it on. + // this permits this to be used even with data types which + // are not wrapped with the name + base::save_override(boost::serialization::make_nvp(NULL, t)); + } + template<class T> + void save_override(const boost::serialization::nvp< T > & t){ + // this is here to remove the "const" requirement. Since + // this class is to be used only for output, it's not required. + base::save_override(t); + } + // specific overrides for attributes - not name value pairs so we + // want to trap them before the above "fall through" + // since we don't want to see these in the output - make them no-ops. + void save_override(const boost::archive::object_id_type & t){} + void save_override(const boost::archive::object_reference_type & t){} + void save_override(const boost::archive::version_type & t){} + void save_override(const boost::archive::class_id_type & t){} + void save_override(const boost::archive::class_id_optional_type & t){} + void save_override(const boost::archive::class_id_reference_type & t){} + void save_override(const boost::archive::class_name_type & t){} + void save_override(const boost::archive::tracking_type & t){} +public: + log_archive(std::ostream & os, unsigned int flags = 0) : + boost::archive::xml_oarchive_impl<log_archive>( + os, + flags | boost::archive::no_header + ) + {} +}; + +#endif // LOG_ARCHIVE_HPP diff --git a/src/boost/libs/serialization/example/polymorphic_portable_binary_iarchive.cpp b/src/boost/libs/serialization/example/polymorphic_portable_binary_iarchive.cpp new file mode 100644 index 00000000..7f2f23e4 --- /dev/null +++ b/src/boost/libs/serialization/example/polymorphic_portable_binary_iarchive.cpp @@ -0,0 +1,34 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// polymorphic_portable_binary_iarchive.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <istream> + +#define BOOST_ARCHIVE_SOURCE +#include "polymorphic_portable_binary_iarchive.hpp" + +// explicitly instantiate for this type of text stream +#include <boost/archive/impl/basic_binary_iarchive.ipp> +#include <boost/archive/impl/archive_pointer_iserializer.ipp> +#include <boost/archive/impl/basic_binary_iprimitive.ipp> + +namespace boost { +namespace archive { + +template class binary_iarchive_impl< + polymorphic_portable_binary_iarchive, + std::istream::char_type, + std::istream::traits_type +>; +template class detail::archive_pointer_iserializer< + polymorphic_portable_binary_iarchive +> ; + +} // namespace archive +} // namespace boost diff --git a/src/boost/libs/serialization/example/polymorphic_portable_binary_iarchive.hpp b/src/boost/libs/serialization/example/polymorphic_portable_binary_iarchive.hpp new file mode 100644 index 00000000..35d99072 --- /dev/null +++ b/src/boost/libs/serialization/example/polymorphic_portable_binary_iarchive.hpp @@ -0,0 +1,35 @@ +#ifndef BOOST_ARCHIVE_POLYMORPHIC_PORTABLE_BINARY_IARCHIVE_HPP +#define BOOST_ARCHIVE_POLYMORPHIC_PORTABLE_BINARY_IARCHIVE_HPP + +// MS compatible compilers support #pragma once +#if defined(_MSC_VER) +# pragma once +#endif + +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// polymorphic_portable_binary_iarchive.hpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <boost/archive/detail/polymorphic_iarchive_dispatch.hpp> +#include "portable_binary_iarchive.hpp" + +typedef boost::archive::detail::polymorphic_iarchive_dispatch< + portable_binary_iarchive +> polymorphic_portable_binary_iarchive; + +#include <boost/version.hpp> +#if BOOST_VERSION > 103401 + // required by export + BOOST_SERIALIZATION_REGISTER_ARCHIVE( + polymorphic_portable_binary_iarchive + ) +#endif + +#endif // BOOST_ARCHIVE_POLYMORPHIC_PORTABLE_BINARY_OARCHIVE_HPP + diff --git a/src/boost/libs/serialization/example/polymorphic_portable_binary_oarchive.cpp b/src/boost/libs/serialization/example/polymorphic_portable_binary_oarchive.cpp new file mode 100644 index 00000000..f77b9021 --- /dev/null +++ b/src/boost/libs/serialization/example/polymorphic_portable_binary_oarchive.cpp @@ -0,0 +1,35 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// polymorphic_portable_binary_oarchive.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <ostream> + +#define BOOST_ARCHIVE_SOURCE +#include "polymorphic_portable_binary_oarchive.hpp" + +// explicitly instantiate for this type of text stream +#include <boost/archive/impl/basic_binary_oarchive.ipp> +#include <boost/archive/impl/archive_pointer_oserializer.ipp> +#include <boost/archive/impl/basic_binary_oprimitive.ipp> + +namespace boost { +namespace archive { + +// explicitly instantiate for this type of binary stream +template class binary_oarchive_impl< + polymorphic_portable_binary_oarchive, + std::ostream::char_type, + std::ostream::traits_type +>; +template class detail::archive_pointer_oserializer< + polymorphic_portable_binary_oarchive +> ; + +} // namespace archive +} // namespace boost diff --git a/src/boost/libs/serialization/example/polymorphic_portable_binary_oarchive.hpp b/src/boost/libs/serialization/example/polymorphic_portable_binary_oarchive.hpp new file mode 100644 index 00000000..71fe42d6 --- /dev/null +++ b/src/boost/libs/serialization/example/polymorphic_portable_binary_oarchive.hpp @@ -0,0 +1,34 @@ +#ifndef BOOST_ARCHIVE_POLYMORPHIC_PORTABLE_BINARY_OARCHIVE_HPP +#define BOOST_ARCHIVE_POLYMORPHIC_PORTABLE_BINARY_OARCHIVE_HPP + +// MS compatible compilers support #pragma once +#if defined(_MSC_VER) +# pragma once +#endif + +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// polymorphic_portable_binary_oarchive.hpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <boost/archive/detail/polymorphic_oarchive_dispatch.hpp> +#include "portable_binary_oarchive.hpp" + +typedef boost::archive::detail::polymorphic_oarchive_dispatch< + portable_binary_oarchive + > polymorphic_portable_binary_oarchive; + +#include <boost/version.hpp> +#if BOOST_VERSION > 103401 + // required by export + BOOST_SERIALIZATION_REGISTER_ARCHIVE( + polymorphic_portable_binary_oarchive + ) +#endif + +#endif // BOOST_ARCHIVE_POLYMORPHIC_PORTABLE_BINARY_OARCHIVE_HPP diff --git a/src/boost/libs/serialization/example/portable_binary_archive.hpp b/src/boost/libs/serialization/example/portable_binary_archive.hpp new file mode 100644 index 00000000..4ab796fb --- /dev/null +++ b/src/boost/libs/serialization/example/portable_binary_archive.hpp @@ -0,0 +1,46 @@ +#ifndef PORTABLE_BINARY_ARCHIVE_HPP +#define PORTABLE_BINARY_ARCHIVE_HPP + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// MS compatible compilers support #pragma once +#if defined(_MSC_VER) +# pragma once +#endif + +#include <boost/config.hpp> +#include <boost/cstdint.hpp> +#include <boost/static_assert.hpp> + +#include <climits> +#if CHAR_BIT != 8 +#error This code assumes an eight-bit byte. +#endif + +#include <boost/archive/basic_archive.hpp> +#include <boost/predef/other/endian.h> + +enum portable_binary_archive_flags { + endian_big = 0x4000, + endian_little = 0x8000 +}; + +//#if ( endian_big <= boost::archive::flags_last ) +//#error archive flags conflict +//#endif + +inline void +reverse_bytes(char size, char *address){ + char * first = address; + char * last = first + size - 1; + for(;first < last;++first, --last){ + char x = *last; + *last = *first; + *first = x; + } +} + +#endif // PORTABLE_BINARY_ARCHIVE_HPP diff --git a/src/boost/libs/serialization/example/portable_binary_iarchive.cpp b/src/boost/libs/serialization/example/portable_binary_iarchive.cpp new file mode 100644 index 00000000..b4bb357d --- /dev/null +++ b/src/boost/libs/serialization/example/portable_binary_iarchive.cpp @@ -0,0 +1,131 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// portable_binary_iarchive.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <istream> +#include <string> + +#include <boost/predef/other/endian.h> +#include <boost/serialization/throw_exception.hpp> +#include <boost/archive/archive_exception.hpp> + +#include "portable_binary_iarchive.hpp" + +void +portable_binary_iarchive::load_impl(boost::intmax_t & l, char maxsize){ + char size; + l = 0; + this->primitive_base_t::load(size); + + if(0 == size){ + return; + } + + bool negative = (size < 0); + if(negative) + size = -size; + + if(size > maxsize) + boost::serialization::throw_exception( + portable_binary_iarchive_exception() + ); + + char * cptr = reinterpret_cast<char *>(& l); + #if BOOST_ENDIAN_BIG_BYTE + cptr += (sizeof(boost::intmax_t) - size); + #endif + this->primitive_base_t::load_binary(cptr, size); + + #if BOOST_ENDIAN_BIG_BYTE + if(m_flags & endian_little) + #else + if(m_flags & endian_big) + #endif + reverse_bytes(size, cptr); + + if(negative) + l = -l; +} + +void +portable_binary_iarchive::load_override( + boost::archive::class_name_type & t +){ + std::string cn; + cn.reserve(BOOST_SERIALIZATION_MAX_KEY_SIZE); + load_override(cn); + if(cn.size() > (BOOST_SERIALIZATION_MAX_KEY_SIZE - 1)) + boost::serialization::throw_exception( + boost::archive::archive_exception( + boost::archive::archive_exception::invalid_class_name) + ); + std::memcpy(t, cn.data(), cn.size()); + // borland tweak + t.t[cn.size()] = '\0'; +} + +void +portable_binary_iarchive::init(unsigned int flags){ + if(0 == (flags & boost::archive::no_header)){ + // read signature in an archive version independent manner + std::string file_signature; + * this >> file_signature; + if(file_signature != boost::archive::BOOST_ARCHIVE_SIGNATURE()) + boost::serialization::throw_exception( + boost::archive::archive_exception( + boost::archive::archive_exception::invalid_signature + ) + ); + // make sure the version of the reading archive library can + // support the format of the archive being read + boost::archive::library_version_type input_library_version; + * this >> input_library_version; + + // extra little .t is to get around borland quirk + if(boost::archive::BOOST_ARCHIVE_VERSION() < input_library_version) + boost::serialization::throw_exception( + boost::archive::archive_exception( + boost::archive::archive_exception::unsupported_version + ) + ); + + #if BOOST_WORKAROUND(__MWERKS__, BOOST_TESTED_AT(0x3205)) + this->set_library_version(input_library_version); + //#else + //#if ! BOOST_WORKAROUND(BOOST_MSVC, <= 1200) + //detail:: + //#endif + boost::archive::detail::basic_iarchive::set_library_version( + input_library_version + ); + #endif + } + unsigned char x; + load(x); + m_flags = x << CHAR_BIT; +} + +#include <boost/archive/impl/archive_serializer_map.ipp> +#include <boost/archive/impl/basic_binary_iprimitive.ipp> + +namespace boost { +namespace archive { + +namespace detail { + template class archive_serializer_map<portable_binary_iarchive>; +} + +template class basic_binary_iprimitive< + portable_binary_iarchive, + std::istream::char_type, + std::istream::traits_type +> ; + +} // namespace archive +} // namespace boost diff --git a/src/boost/libs/serialization/example/portable_binary_iarchive.hpp b/src/boost/libs/serialization/example/portable_binary_iarchive.hpp new file mode 100644 index 00000000..3730660c --- /dev/null +++ b/src/boost/libs/serialization/example/portable_binary_iarchive.hpp @@ -0,0 +1,204 @@ +#ifndef PORTABLE_BINARY_IARCHIVE_HPP +#define PORTABLE_BINARY_IARCHIVE_HPP + +// MS compatible compilers support #pragma once +#if defined(_MSC_VER) +# pragma once +#endif + +#if defined(_MSC_VER) +#pragma warning( push ) +#pragma warning( disable : 4244 ) +#endif + +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// portable_binary_iarchive.hpp + +// (C) Copyright 2002-7 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <istream> +#include <boost/serialization/string.hpp> +#include <boost/serialization/item_version_type.hpp> +#include <boost/archive/archive_exception.hpp> +#include <boost/archive/basic_binary_iprimitive.hpp> +#include <boost/archive/detail/common_iarchive.hpp> +#include <boost/archive/detail/register_archive.hpp> + +#include "portable_binary_archive.hpp" + +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// exception to be thrown if integer read from archive doesn't fit +// variable being loaded +class portable_binary_iarchive_exception : + public boost::archive::archive_exception +{ +public: + enum exception_code { + incompatible_integer_size + } m_exception_code ; + portable_binary_iarchive_exception(exception_code c = incompatible_integer_size ) : + boost::archive::archive_exception(boost::archive::archive_exception::other_exception), + m_exception_code(c) + {} + virtual const char *what( ) const throw( ) + { + const char *msg = "programmer error"; + switch(m_exception_code){ + case incompatible_integer_size: + msg = "integer cannot be represented"; + break; + default: + msg = boost::archive::archive_exception::what(); + assert(false); + break; + } + return msg; + } +}; + +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// "Portable" input binary archive. It addresses integer size and endienness so +// that binary archives can be passed across systems. Note:floating point types +// not addressed here +class portable_binary_iarchive : + public boost::archive::basic_binary_iprimitive< + portable_binary_iarchive, + std::istream::char_type, + std::istream::traits_type + >, + public boost::archive::detail::common_iarchive< + portable_binary_iarchive + > + { + typedef boost::archive::basic_binary_iprimitive< + portable_binary_iarchive, + std::istream::char_type, + std::istream::traits_type + > primitive_base_t; + typedef boost::archive::detail::common_iarchive< + portable_binary_iarchive + > archive_base_t; +#ifndef BOOST_NO_MEMBER_TEMPLATE_FRIENDS +public: +#else + friend archive_base_t; + friend primitive_base_t; // since with override load below + friend class boost::archive::detail::interface_iarchive< + portable_binary_iarchive + >; + friend class boost::archive::load_access; +protected: +#endif + unsigned int m_flags; + void load_impl(boost::intmax_t & l, char maxsize); + + // default fall through for any types not specified here + template<class T> + void load(T & t){ + boost::intmax_t l; + load_impl(l, sizeof(T)); + // use cast to avoid compile time warning + //t = static_cast< T >(l); + t = T(l); + } + void load(boost::serialization::item_version_type & t){ + boost::intmax_t l; + load_impl(l, sizeof(boost::serialization::item_version_type)); + // use cast to avoid compile time warning + t = boost::serialization::item_version_type(l); + } + void load(boost::archive::version_type & t){ + boost::intmax_t l; + load_impl(l, sizeof(boost::archive::version_type)); + // use cast to avoid compile time warning + t = boost::archive::version_type(l); + } + void load(boost::archive::class_id_type & t){ + boost::intmax_t l; + load_impl(l, sizeof(boost::archive::class_id_type)); + // use cast to avoid compile time warning + t = boost::archive::class_id_type(static_cast<int>(l)); + } + void load(std::string & t){ + this->primitive_base_t::load(t); + } + #ifndef BOOST_NO_STD_WSTRING + void load(std::wstring & t){ + this->primitive_base_t::load(t); + } + #endif + void load(float & t){ + this->primitive_base_t::load(t); + // floats not supported + //BOOST_STATIC_ASSERT(false); + } + void load(double & t){ + this->primitive_base_t::load(t); + // doubles not supported + //BOOST_STATIC_ASSERT(false); + } + void load(char & t){ + this->primitive_base_t::load(t); + } + void load(unsigned char & t){ + this->primitive_base_t::load(t); + } + typedef boost::archive::detail::common_iarchive<portable_binary_iarchive> + detail_common_iarchive; + template<class T> + void load_override(T & t){ + this->detail_common_iarchive::load_override(t); + } + void load_override(boost::archive::class_name_type & t); + // binary files don't include the optional information + void load_override(boost::archive::class_id_optional_type &){} + + void init(unsigned int flags); +public: + portable_binary_iarchive(std::istream & is, unsigned flags = 0) : + primitive_base_t( + * is.rdbuf(), + 0 != (flags & boost::archive::no_codecvt) + ), + archive_base_t(flags), + m_flags(0) + { + init(flags); + } + + portable_binary_iarchive( + std::basic_streambuf< + std::istream::char_type, + std::istream::traits_type + > & bsb, + unsigned int flags + ) : + primitive_base_t( + bsb, + 0 != (flags & boost::archive::no_codecvt) + ), + archive_base_t(flags), + m_flags(0) + { + init(flags); + } +}; + +// required by export in boost version > 1.34 +#ifdef BOOST_SERIALIZATION_REGISTER_ARCHIVE + BOOST_SERIALIZATION_REGISTER_ARCHIVE(portable_binary_iarchive) +#endif + +// required by export in boost <= 1.34 +#define BOOST_ARCHIVE_CUSTOM_IARCHIVE_TYPES portable_binary_iarchive + +#if defined(_MSC_VER) +#pragma warning( pop ) +#endif + +#endif // PORTABLE_BINARY_IARCHIVE_HPP diff --git a/src/boost/libs/serialization/example/portable_binary_oarchive.cpp b/src/boost/libs/serialization/example/portable_binary_oarchive.cpp new file mode 100644 index 00000000..c4f6aca5 --- /dev/null +++ b/src/boost/libs/serialization/example/portable_binary_oarchive.cpp @@ -0,0 +1,98 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// portable_binary_oarchive.cpp + +// (C) Copyright 2002-7 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <ostream> +#include <boost/predef/other/endian.h> +#include "portable_binary_oarchive.hpp" + +void +portable_binary_oarchive::save_impl( + const boost::intmax_t l, + const char maxsize +){ + char size = 0; + + if(l == 0){ + this->primitive_base_t::save(size); + return; + } + + boost::intmax_t ll; + bool negative = (l < 0); + if(negative) + ll = -l; + else + ll = l; + + do{ + ll >>= CHAR_BIT; + ++size; + }while(ll != 0); + + this->primitive_base_t::save( + static_cast<char>(negative ? -size : size) + ); + + if(negative) + ll = -l; + else + ll = l; + char * cptr = reinterpret_cast<char *>(& ll); + #if BOOST_ENDIAN_BIG_BYTE + cptr += (sizeof(boost::intmax_t) - size); + if(m_flags & endian_little) + reverse_bytes(size, cptr); + #else + if(m_flags & endian_big) + reverse_bytes(size, cptr); + #endif + this->primitive_base_t::save_binary(cptr, size); +} + +void +portable_binary_oarchive::init(unsigned int flags) { + if(m_flags == (endian_big | endian_little)){ + boost::serialization::throw_exception( + portable_binary_oarchive_exception() + ); + } + if(0 == (flags & boost::archive::no_header)){ + // write signature in an archive version independent manner + const std::string file_signature( + boost::archive::BOOST_ARCHIVE_SIGNATURE() + ); + * this << file_signature; + // write library version + const boost::archive::library_version_type v( + boost::archive::BOOST_ARCHIVE_VERSION() + ); + * this << v; + } + save(static_cast<unsigned char>(m_flags >> CHAR_BIT)); +} + +#include <boost/archive/impl/archive_serializer_map.ipp> +#include <boost/archive/impl/basic_binary_oprimitive.ipp> + +namespace boost { +namespace archive { + +namespace detail { + template class archive_serializer_map<portable_binary_oarchive>; +} + +template class basic_binary_oprimitive< + portable_binary_oarchive, + std::ostream::char_type, + std::ostream::traits_type +> ; + +} // namespace archive +} // namespace boost diff --git a/src/boost/libs/serialization/example/portable_binary_oarchive.hpp b/src/boost/libs/serialization/example/portable_binary_oarchive.hpp new file mode 100644 index 00000000..317aa1d7 --- /dev/null +++ b/src/boost/libs/serialization/example/portable_binary_oarchive.hpp @@ -0,0 +1,191 @@ +#ifndef PORTABLE_BINARY_OARCHIVE_HPP +#define PORTABLE_BINARY_OARCHIVE_HPP + +// MS compatible compilers support #pragma once +#if defined(_MSC_VER) +# pragma once +#endif + +#if defined(_MSC_VER) +#pragma warning( push ) +#pragma warning( disable : 4244 ) +#endif + +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// portable_binary_oarchive.hpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <ostream> +#include <boost/serialization/string.hpp> +#include <boost/archive/archive_exception.hpp> +#include <boost/archive/basic_binary_oprimitive.hpp> +#include <boost/archive/detail/common_oarchive.hpp> +#include <boost/archive/detail/register_archive.hpp> + +#include "portable_binary_archive.hpp" + +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// exception to be thrown if integer read from archive doesn't fit +// variable being loaded +class portable_binary_oarchive_exception : + public boost::archive::archive_exception +{ +public: + typedef enum { + invalid_flags + } exception_code; + portable_binary_oarchive_exception(exception_code c = invalid_flags ) + {} + virtual const char *what( ) const throw( ) + { + const char *msg = "programmer error"; + switch(code){ + case invalid_flags: + msg = "cannot be both big and little endian"; + default: + boost::archive::archive_exception::what(); + } + return msg; + } +}; + +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// "Portable" output binary archive. This is a variation of the native binary +// archive. it addresses integer size and endienness so that binary archives can +// be passed across systems. Note:floating point types not addressed here + +class portable_binary_oarchive : + public boost::archive::basic_binary_oprimitive< + portable_binary_oarchive, + std::ostream::char_type, + std::ostream::traits_type + >, + public boost::archive::detail::common_oarchive< + portable_binary_oarchive + > +{ + typedef boost::archive::basic_binary_oprimitive< + portable_binary_oarchive, + std::ostream::char_type, + std::ostream::traits_type + > primitive_base_t; + typedef boost::archive::detail::common_oarchive< + portable_binary_oarchive + > archive_base_t; +#ifndef BOOST_NO_MEMBER_TEMPLATE_FRIENDS +public: +#else + friend archive_base_t; + friend primitive_base_t; // since with override save below + friend class boost::archive::detail::interface_oarchive< + portable_binary_oarchive + >; + friend class boost::archive::save_access; +protected: +#endif + unsigned int m_flags; + void save_impl(const boost::intmax_t l, const char maxsize); + // add base class to the places considered when matching + // save function to a specific set of arguments. Note, this didn't + // work on my MSVC 7.0 system so we use the sure-fire method below + // using archive_base_t::save; + + // default fall through for any types not specified here + template<class T> + void save(const T & t){ + save_impl(t, sizeof(T)); + } + void save(const std::string & t){ + this->primitive_base_t::save(t); + } + #ifndef BOOST_NO_STD_WSTRING + void save(const std::wstring & t){ + this->primitive_base_t::save(t); + } + #endif + void save(const float & t){ + this->primitive_base_t::save(t); + // floats not supported + //BOOST_STATIC_ASSERT(false); + } + void save(const double & t){ + this->primitive_base_t::save(t); + // doubles not supported + //BOOST_STATIC_ASSERT(false); + } + void save(const char & t){ + this->primitive_base_t::save(t); + } + void save(const unsigned char & t){ + this->primitive_base_t::save(t); + } + + // default processing - kick back to base class. Note the + // extra stuff to get it passed borland compilers + typedef boost::archive::detail::common_oarchive<portable_binary_oarchive> + detail_common_oarchive; + template<class T> + void save_override(T & t){ + this->detail_common_oarchive::save_override(t); + } + // explicitly convert to char * to avoid compile ambiguities + void save_override(const boost::archive::class_name_type & t){ + const std::string s(t); + * this << s; + } + // binary files don't include the optional information + void save_override( + const boost::archive::class_id_optional_type & /* t */ + ){} + + void init(unsigned int flags); +public: + portable_binary_oarchive(std::ostream & os, unsigned flags = 0) : + primitive_base_t( + * os.rdbuf(), + 0 != (flags & boost::archive::no_codecvt) + ), + archive_base_t(flags), + m_flags(flags & (endian_big | endian_little)) + { + init(flags); + } + + portable_binary_oarchive( + std::basic_streambuf< + std::ostream::char_type, + std::ostream::traits_type + > & bsb, + unsigned int flags + ) : + primitive_base_t( + bsb, + 0 != (flags & boost::archive::no_codecvt) + ), + archive_base_t(flags), + m_flags(0) + { + init(flags); + } +}; + + +// required by export in boost version > 1.34 +#ifdef BOOST_SERIALIZATION_REGISTER_ARCHIVE + BOOST_SERIALIZATION_REGISTER_ARCHIVE(portable_binary_oarchive) +#endif + +// required by export in boost <= 1.34 +#define BOOST_ARCHIVE_CUSTOM_OARCHIVE_TYPES portable_binary_oarchive + +#if defined(_MSC_VER) +#pragma warning( pop ) +#endif + +#endif // PORTABLE_BINARY_OARCHIVE_HPP diff --git a/src/boost/libs/serialization/example/simple_log_archive.hpp b/src/boost/libs/serialization/example/simple_log_archive.hpp new file mode 100644 index 00000000..e85f322f --- /dev/null +++ b/src/boost/libs/serialization/example/simple_log_archive.hpp @@ -0,0 +1,167 @@ +#ifndef BOOST_SIMPLE_LOG_ARCHIVE_HPP +#define BOOST_SIMPLE_LOG_ARCHIVE_HPP + +// MS compatible compilers support #pragma once +#if defined(_MSC_VER) +# pragma once +#endif + +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// simple_log_archive.hpp + +// (C) Copyright 2010 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <ostream> +#include <cstddef> // std::size_t + +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::size_t; +} // namespace std +#endif + +#include <boost/type_traits/is_enum.hpp> +#include <boost/mpl/bool.hpp> +#include <boost/mpl/eval_if.hpp> +#include <boost/mpl/int.hpp> +#include <boost/mpl/equal_to.hpp> +#include <boost/serialization/nvp.hpp> +#include <boost/serialization/array.hpp> +#include <boost/serialization/string.hpp> +#include <boost/serialization/access.hpp> + +///////////////////////////////////////////////////////////////////////// +// log data to an output stream. This illustrates a simpler implemenation +// of text output which is useful for getting a formatted display of +// any serializable class. Intended to be useful as a debugging aid. +class simple_log_archive { + std::ostream & m_os; + unsigned int m_depth; + + template<class Archive> + struct save_enum_type { + template<class T> + static void invoke(Archive &ar, const T &t){ + ar.m_os << static_cast<int>(t); + } + }; + template<class Archive> + struct save_primitive { + template<class T> + static void invoke(Archive & ar, const T & t){ + ar.m_os << t; + } + }; + template<class Archive> + struct save_only { + template<class T> + static void invoke(Archive & ar, const T & t){ + // make sure call is routed through the highest interface that might + // be specialized by the user. + boost::serialization::serialize_adl( + ar, + const_cast<T &>(t), + ::boost::serialization::version< T >::value + ); + } + }; + template<class T> + void save(const T &t){ + typedef + BOOST_DEDUCED_TYPENAME boost::mpl::eval_if<boost::is_enum< T >, + boost::mpl::identity<save_enum_type<simple_log_archive> >, + //else + BOOST_DEDUCED_TYPENAME boost::mpl::eval_if< + // if its primitive + boost::mpl::equal_to< + boost::serialization::implementation_level< T >, + boost::mpl::int_<boost::serialization::primitive_type> + >, + boost::mpl::identity<save_primitive<simple_log_archive> >, + // else + boost::mpl::identity<save_only<simple_log_archive> > + > >::type typex; + typex::invoke(*this, t); + } + #ifndef BOOST_NO_STD_WSTRING + void save(const std::wstring &ws){ + m_os << "wide string types not suported in log archive"; + } + #endif + +public: + /////////////////////////////////////////////////// + // Implement requirements for archive concept + + typedef boost::mpl::bool_<false> is_loading; + typedef boost::mpl::bool_<true> is_saving; + + // this can be a no-op since we ignore pointer polymorphism + template<class T> + void register_type(const T * = NULL){} + + unsigned int get_library_version(){ + return 0; + } + + void + save_binary(const void *address, std::size_t count){ + m_os << "save_binary not implemented"; + } + + // the << operators + template<class T> + simple_log_archive & operator<<(T const & t){ + m_os << ' '; + save(t); + return * this; + } + template<class T> + simple_log_archive & operator<<(T * const t){ + m_os << " ->"; + if(NULL == t) + m_os << " null"; + else + *this << * t; + return * this; + } + template<class T, int N> + simple_log_archive & operator<<(const T (&t)[N]){ + return *this << boost::serialization::make_array( + static_cast<const T *>(&t[0]), + N + ); + } + template<class T> + simple_log_archive & operator<<(const boost::serialization::nvp< T > & t){ + m_os << '\n'; // start line with each named object + // indent according to object depth + for(unsigned int i = 0; i < m_depth; ++i) + m_os << ' '; + ++m_depth; + m_os << t.name(); // output the name of the object + * this << t.const_value(); + --m_depth; + return * this; + } + + // the & operator + template<class T> + simple_log_archive & operator&(const T & t){ + return * this << t; + } + /////////////////////////////////////////////// + + simple_log_archive(std::ostream & os) : + m_os(os), + m_depth(0) + {} +}; + +#endif // BOOST_SIMPLE_LOG_ARCHIVE_HPP diff --git a/src/boost/libs/serialization/index.html b/src/boost/libs/serialization/index.html new file mode 100644 index 00000000..ad01a7c5 --- /dev/null +++ b/src/boost/libs/serialization/index.html @@ -0,0 +1,15 @@ +<html> +<!-- +(C) Copyright 2002-4 Robert Ramey - http://www.rrsd.com . +Use, modification and distribution is subject to the Boost Software +License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +http://www.boost.org/LICENSE_1_0.txt) +--> +<head> +<meta http-equiv="refresh" content="0; URL=doc/index.html"> +</head> +<body> +Automatic redirection failed, please go to +<a href="doc/index.html">doc/index.html</a>. +</body> +</html>
\ No newline at end of file diff --git a/src/boost/libs/serialization/meta/libraries.json b/src/boost/libs/serialization/meta/libraries.json new file mode 100644 index 00000000..55d77710 --- /dev/null +++ b/src/boost/libs/serialization/meta/libraries.json @@ -0,0 +1,14 @@ +{ + "key": "serialization", + "name": "Serialization", + "authors": [ + "Robert Ramey" + ], + "description": "Serialization for persistence and marshalling.", + "category": [ + "IO" + ], + "maintainers": [ + "Robert Ramey <ramey -at- rrsd.com>" + ] +} diff --git a/src/boost/libs/serialization/performance/Jamfile.v2 b/src/boost/libs/serialization/performance/Jamfile.v2 new file mode 100644 index 00000000..5ec2a296 --- /dev/null +++ b/src/boost/libs/serialization/performance/Jamfile.v2 @@ -0,0 +1,48 @@ +# Boost serialization Library performance test Jamfile + +# (C) Copyright Robert Ramey 2002-2004. +# Use, modification, and distribution are subject to the +# Boost Software License, Version 1.0. (See accompanying file +# LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) +# + +project libs/serialization/performance + : default-build release + : id serialization_performance + ; + +# import rules from the boost serialization test +# import ../util/test : test-bsl-run-no-lib ; +import ../util/test : + run-template + run-invoke + run-winvoke + test-bsl-run-no-lib + test-bsl-run + test-bsl-run_archive + test-bsl-run_files + test-bsl-run_polymorphic_archive +; + +BOOST_ARCHIVE_LIST = [ modules.peek : BOOST_ARCHIVE_LIST ] ; + +test-suite "performance" : + [ test-bsl-run_files peformance_array : ../test/A ] +# [ test-bsl-run_files performance_binary ] +# [ test-bsl-run_files performance_polymorphic ] +# [ test-bsl-run_files performance_vector ] +# [ test-bsl-run_files performance_no_rtti ] +# [ test-bsl-run_files performance_simple_class ] +# [ test-bsl-run_polymorphic_archive performance_polymorphic : ../test/test_polymorphic_A ] + + [ test-bsl-run-no-lib performance_iterators ] + [ test-bsl-run-no-lib performance_iterators_base64 ] +# [ test-bsl-run-no-lib performance_utf8_codecvt +# : ../src/utf8_codecvt_facet +# : # <dependency>../../config/test/all//BOOST_NO_STD_WSTREAMBUF +# ] +# [ test-bsl-run-no-lib performance_codecvt_null +# : ../src/codecvt_null +# : # <dependency>../../config/test/all//BOOST_NO_STD_WSTREAMBUF +# ] +; diff --git a/src/boost/libs/serialization/performance/binary_archive.hpp b/src/boost/libs/serialization/performance/binary_archive.hpp new file mode 100644 index 00000000..3569bcf3 --- /dev/null +++ b/src/boost/libs/serialization/performance/binary_archive.hpp @@ -0,0 +1,22 @@ +// (C) Copyright 2002-4 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. +// (C) Copyright 2002-4 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +// binary_archive +#include <boost/archive/binary_oarchive.hpp> +typedef boost::archive::binary_oarchive test_oarchive; +typedef std::ofstream test_ostream; +#include <boost/archive/binary_iarchive.hpp> +typedef boost::archive::binary_iarchive test_iarchive; +typedef std::ifstream test_istream; +#define TEST_STREAM_FLAGS std::ios::binary + diff --git a/src/boost/libs/serialization/performance/binary_warchive.hpp b/src/boost/libs/serialization/performance/binary_warchive.hpp new file mode 100644 index 00000000..929f3a37 --- /dev/null +++ b/src/boost/libs/serialization/performance/binary_warchive.hpp @@ -0,0 +1,14 @@ +// (C) Copyright 2002-4 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. +// binary_warchive +#include <boost/archive/binary_woarchive.hpp> +typedef boost::archive::binary_woarchive test_oarchive; +typedef std::wofstream test_ostream; +#include <boost/archive/binary_wiarchive.hpp> +typedef boost::archive::binary_wiarchive test_iarchive; +typedef std::wifstream test_istream; +#define TEST_STREAM_FLAGS std::wios::binary diff --git a/src/boost/libs/serialization/performance/peformance_array.cpp b/src/boost/libs/serialization/performance/peformance_array.cpp new file mode 100644 index 00000000..40159013 --- /dev/null +++ b/src/boost/libs/serialization/performance/peformance_array.cpp @@ -0,0 +1,118 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_array.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <fstream> +#include <cstdio> // remove +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include "../test/test_tools.hpp" + +#include <boost/preprocessor/stringize.hpp> +//#include <boost/preprocessor/cat.hpp> +// the following fails with (only!) gcc 3.4 +// #include BOOST_PP_STRINGIZE(BOOST_PP_CAT(../test/,BOOST_ARCHIVE_TEST)) +// just copy over the files from the test directory +#include BOOST_PP_STRINGIZE(BOOST_ARCHIVE_TEST) + +#include <boost/detail/no_exceptions_support.hpp> +#include <boost/archive/archive_exception.hpp> + +#include <boost/serialization/nvp.hpp> +#include "../test/A.hpp" +#include "../test/A.ipp" + +struct array_equal_to //: public std::binary_function<T, T, bool> +{ +template<class T, class U> + bool operator()(const T & _Left, const U & _Right) const + { + // consider alignment + int count_left = sizeof(_Left) / ( + static_cast<const char *>(static_cast<const void *>(&_Left[1])) + - static_cast<const char *>(static_cast<const void *>(&_Left[0])) + ); + int count_right = sizeof(_Right) / ( + static_cast<const char *>(static_cast<const void *>(&_Right[1])) + - static_cast<const char *>(static_cast<const void *>(&_Right[0])) + ); + if(count_right != count_left) + return false; + while(count_left-- > 0){ + if(_Left[count_left] == _Right[count_left]) + continue; + return false; + } + return true; + } +}; + +template <class T> +int test_array(T) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + // test array of objects + const T a_array[10]={T(),T(),T(),T(),T(),T(),T(),T(),T(),T()}; + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("a_array", a_array); + } + { + T a_array1[10]; + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("a_array", a_array1); + + array_equal_to/*<A[10]>*/ Compare; + BOOST_CHECK(Compare(a_array, a_array1)); + } + { + T a_array1[9]; + test_istream is(testfile, TEST_STREAM_FLAGS); + BOOST_TRY { + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + bool exception_invoked = false; + BOOST_TRY { + ia >> boost::serialization::make_nvp("a_array", a_array1); + } + BOOST_CATCH (boost::archive::archive_exception ae){ + BOOST_CHECK( + boost::archive::archive_exception::array_size_too_short + == ae.code + ); + exception_invoked = true; + } + BOOST_CATCH_END + BOOST_CHECK(exception_invoked); + } + BOOST_CATCH (boost::archive::archive_exception ae){} + BOOST_CATCH_END + } + std::remove(testfile); + return EXIT_SUCCESS; +} + +int test_main( int /* argc */, char* /* argv */[] ) +{ + int res = test_array(A()); + // test an int array for which optimized versions should be available + if (res == EXIT_SUCCESS) + res = test_array(0); + return res; +} + +// EOF diff --git a/src/boost/libs/serialization/performance/performance_binary.cpp b/src/boost/libs/serialization/performance/performance_binary.cpp new file mode 100644 index 00000000..7c817b20 --- /dev/null +++ b/src/boost/libs/serialization/performance/performance_binary.cpp @@ -0,0 +1,96 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_simple_class.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <fstream> + +#include <cstdlib> // for rand() +#include <cstdio> // remove +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::rand; + using ::remove; +} +#endif + +#include "../test/test_tools.hpp" +#include <boost/preprocessor/stringize.hpp> +// #include <boost/preprocessor/cat.hpp> +// the following fails with (only!) gcc 3.4 +// #include BOOST_PP_STRINGIZE(BOOST_PP_CAT(../test/,BOOST_ARCHIVE_TEST)) +// just copy over the files from the test directory +#include BOOST_PP_STRINGIZE(BOOST_ARCHIVE_TEST) + +#include <boost/serialization/nvp.hpp> +#include <boost/serialization/binary_object.hpp> + +class A { + friend class boost::serialization::access; + char data[150]; + // note: from an aesthetic perspective, I would much prefer to have this + // defined out of line. Unfortunately, this trips a bug in the VC 6.0 + // compiler. So hold our nose and put it her to permit running of tests. + template<class Archive> + void serialize(Archive & ar, const unsigned int /* file_version */){ + ar & boost::serialization::make_nvp( + "data", + boost::serialization::make_binary_object(data, sizeof(data)) + ); + } + +public: + A(); + bool operator==(const A & rhs) const; +}; + +A::A(){ + int i = sizeof(data); + while(i-- > 0) + data[i] = 0xff & std::rand(); +} + +bool A::operator==(const A & rhs) const { + int i = sizeof(data); + while(i-- > 0) + if(data[i] != rhs.data[i]) + return false; + return true; +} + +int test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + const A a; + A a1; + const int i = 12345; + int i1 = 34790; + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << BOOST_SERIALIZATION_NVP(a); + // note: add a little bit on the end of the archive to detect + // failure of text mode binary. + oa << BOOST_SERIALIZATION_NVP(i); + } + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> BOOST_SERIALIZATION_NVP(a1); + ia >> BOOST_SERIALIZATION_NVP(i1); + } + BOOST_CHECK(i == i1); + BOOST_CHECK(a == a1); + std::remove(testfile); + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/performance/performance_codecvt_null.cpp b/src/boost/libs/serialization/performance/performance_codecvt_null.cpp new file mode 100644 index 00000000..70dd573e --- /dev/null +++ b/src/boost/libs/serialization/performance/performance_codecvt_null.cpp @@ -0,0 +1,136 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_codecvt_null.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution. Note: compilation with compilers +// which use wchar_t as 2 byte objects will emit warnings. These should be +// ignored. + +#include <algorithm> +#include <fstream> +#include <iostream> +#include <iterator> +#include <locale> +#include <vector> +#include <cstddef> + +#include <cstdio> // remove +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include "test_tools.hpp" + +#include <boost/archive/add_facet.hpp> +#include <boost/archive/codecvt_null.hpp> +#include <boost/archive/iterators/ostream_iterator.hpp> +#include <boost/archive/iterators/istream_iterator.hpp> + +template<std::size_t S> +struct test_data +{ + static wchar_t wchar_encoding[]; +}; + +template<> +wchar_t test_data<2>::wchar_encoding[] = { + 0x0001, + 0x007f, + 0x0080, + 0x07ff, + 0x0800, + 0x7fff +}; + +template<> +wchar_t test_data<4>::wchar_encoding[] = { + 0x00000001, + 0x0000007f, + 0x00000080, + 0x000007ff, + 0x00000800, + 0x0000ffff, + 0x00010000, + 0x0010ffff, + 0x001fffff, + 0x00200000, + 0x03ffffff, + 0x04000000, + 0x7fffffff +}; + +#include <iostream> + +int test_main( int /* argc */, char* /* argv */[] ) { + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + std::locale old_loc; + std::locale * null_locale = + boost::archive::add_facet(old_loc, new boost::archive::codecvt_null<wchar_t>); + + typedef test_data<sizeof(wchar_t)> td; + { + std::wofstream ofs; + ofs.imbue(*null_locale); + ofs.open(testfile, std::ios::binary); + std::copy( + td::wchar_encoding, + #if ! defined(__BORLANDC__) + // borland 5.60 complains about this + td::wchar_encoding + sizeof(td::wchar_encoding)/sizeof(wchar_t), + #else + // so use this instead + td::wchar_encoding + 6, + #endif + boost::archive::iterators::ostream_iterator<wchar_t>(ofs) + ); + } + bool ok = false; + { + std::wifstream ifs; + ifs.imbue(*null_locale); + ifs.open(testfile, std::ios::binary); + ok = std::equal( + td::wchar_encoding, + #if ! defined(__BORLANDC__) + // borland 5.60 complains about this + td::wchar_encoding + sizeof(td::wchar_encoding)/sizeof(wchar_t), + #else + // so use this instead + td::wchar_encoding + 6, + #endif + boost::archive::iterators::istream_iterator<wchar_t>(ifs) + ); + } + + BOOST_CHECK(ok); + { + std::wofstream ofs("testfile2"); + ofs.imbue(*null_locale); + int i = 10; + ofs << i; + ofs.close(); + + std::wifstream ifs("testfile2"); + ifs.imbue(*null_locale); + int i2; + ifs >> i2; + std::cout << "i=" << i << std::endl; + std::cout << "i2=" << i2 << std::endl; + BOOST_CHECK(i == i2); + ifs.close(); + } + + delete null_locale; + std::remove(testfile); + return EXIT_SUCCESS; +} + diff --git a/src/boost/libs/serialization/performance/performance_iterators.cpp b/src/boost/libs/serialization/performance/performance_iterators.cpp new file mode 100644 index 00000000..869b6eda --- /dev/null +++ b/src/boost/libs/serialization/performance/performance_iterators.cpp @@ -0,0 +1,213 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_iterators.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +#include <algorithm> +#include <vector> +#include <cstdlib> // for rand +#include <functional> +#include <sstream> // used to test stream iterators + +#include <boost/config.hpp> +#ifdef BOOST_NO_STDC_NAMESPACE +namespace std{ + using ::rand; +} +#endif + +#include <boost/detail/workaround.hpp> +#if BOOST_WORKAROUND(BOOST_DINKUMWARE_STDLIB, == 1) +#include <boost/archive/dinkumware.hpp> +#endif + +#ifndef BOOST_NO_CWCHAR +#include <boost/archive/iterators/mb_from_wchar.hpp> +#include <boost/archive/iterators/wchar_from_mb.hpp> +#endif +#include <boost/archive/iterators/xml_escape.hpp> +#include <boost/archive/iterators/xml_unescape.hpp> +#include <boost/archive/iterators/transform_width.hpp> +#include <boost/archive/iterators/istream_iterator.hpp> +#include <boost/archive/iterators/ostream_iterator.hpp> + +#include "../test/test_tools.hpp" + +#ifndef BOOST_NO_CWCHAR + +void test_wchar_from_mb(const wchar_t *la, const char * a, const unsigned int size){ + typedef boost::archive::iterators::wchar_from_mb<const char *> translator; + BOOST_CHECK(( + std::equal( + translator(BOOST_MAKE_PFTO_WRAPPER(a)), + translator(BOOST_MAKE_PFTO_WRAPPER(a + size)), + la + ) + )); +} + +void test_mb_from_wchar(const char * a, const wchar_t *la, const unsigned int size){ + typedef boost::archive::iterators::mb_from_wchar<const wchar_t *> translator; + BOOST_CHECK( + std::equal( + translator(BOOST_MAKE_PFTO_WRAPPER(la)), + translator(BOOST_MAKE_PFTO_WRAPPER(la + size)), + a + ) + ); +} + +#endif + +template<class CharType> +void test_xml_escape( + const CharType * xml_escaped, + const CharType * xml, + unsigned int size +){ + typedef boost::archive::iterators::xml_escape<const CharType *> translator; + + BOOST_CHECK( + std::equal( + translator(BOOST_MAKE_PFTO_WRAPPER(xml)), + translator(BOOST_MAKE_PFTO_WRAPPER(xml + size)), + xml_escaped + ) + ); +} + +template<class CharType> +void test_xml_unescape( + const CharType * xml, + const CharType * xml_escaped, + unsigned int size +){ + + // test xml_unescape + typedef boost::archive::iterators::xml_unescape<const CharType *> translator; + + BOOST_CHECK( + std::equal( + translator(BOOST_MAKE_PFTO_WRAPPER(xml_escaped)), + translator(BOOST_MAKE_PFTO_WRAPPER(xml_escaped + size)), + xml + ) + ); +} + +template<int BitsOut, int BitsIn> +void test_transform_width(unsigned int size){ + // test transform_width + char rawdata[8]; + + char * rptr; + for(rptr = rawdata + 6; rptr-- > rawdata;) + *rptr = std::rand(); + + // convert 8 to 6 bit characters + typedef boost::archive::iterators::transform_width< + char *, BitsOut, BitsIn + > translator1; + + std::vector<char> v6; + + std::copy( + translator1(BOOST_MAKE_PFTO_WRAPPER(static_cast<char *>(rawdata))), + translator1(BOOST_MAKE_PFTO_WRAPPER(rawdata + size)), + std::back_inserter(v6) + ); + + // check to see we got the expected # of characters out + if(0 == size) + BOOST_CHECK(v6.size() == 0); + else + BOOST_CHECK(v6.size() == (size * BitsIn - 1 ) / BitsOut + 1); + + typedef boost::archive::iterators::transform_width< + std::vector<char>::iterator, BitsIn, BitsOut + > translator2; + + BOOST_CHECK( + std::equal( + rawdata, + rawdata + size, + translator2(BOOST_MAKE_PFTO_WRAPPER(v6.begin())) + ) + ); + +} + +template<class CharType> +void test_stream_iterators( + const CharType * test_data, + unsigned int size +){ + std::basic_stringstream<CharType> ss; + boost::archive::iterators::ostream_iterator<CharType> osi = + boost::archive::iterators::ostream_iterator<CharType>(ss); + std::copy(test_data, test_data + size, osi); + + BOOST_CHECK(size == ss.str().size()); + + boost::archive::iterators::istream_iterator<CharType> isi = + boost::archive::iterators::istream_iterator<CharType>(ss); + BOOST_CHECK(std::equal(test_data, test_data + size,isi)); +} + +int +test_main(int /* argc */, char* /* argv */ [] ) +{ + const char xml[] = "<+>+&+\"+'"; + const char xml_escaped[] = "<+>+&+"+'"; + test_xml_escape<const char>( + xml_escaped, + xml, + sizeof(xml) / sizeof(char) - 1 + ); + test_xml_unescape<const char>( + xml, + xml_escaped, + sizeof(xml_escaped) / sizeof(char) - 1 + ); + + const char a[] = "abcdefghijklmnopqrstuvwxyz"; + + #ifndef BOOST_NO_CWCHAR + const wchar_t wxml[] = L"<+>+&+\"+'"; + const wchar_t wxml_escaped[] = L"<+>+&+"+'"; + test_xml_escape<const wchar_t>( + wxml_escaped, + wxml, + sizeof(wxml) / sizeof(wchar_t) - 1 + ); + test_xml_unescape<const wchar_t>( + wxml, + wxml_escaped, + sizeof(wxml_escaped) / sizeof(wchar_t) - 1 + ); + + const wchar_t la[] = L"abcdefghijklmnopqrstuvwxyz"; + + test_wchar_from_mb(la, a, sizeof(a) / sizeof(char) - 1); + test_mb_from_wchar(a, la, sizeof(la) / sizeof(wchar_t) - 1); + + test_stream_iterators<wchar_t>(la, sizeof(la)/sizeof(wchar_t) - 1); + #endif + + test_stream_iterators<char>(a, sizeof(a) - 1); + + test_transform_width<6, 8>(0); + test_transform_width<6, 8>(1); + test_transform_width<6, 8>(2); + test_transform_width<6, 8>(3); + test_transform_width<6, 8>(4); + test_transform_width<6, 8>(5); + test_transform_width<6, 8>(6); + test_transform_width<6, 8>(7); + test_transform_width<6, 8>(8); + + return EXIT_SUCCESS; +} diff --git a/src/boost/libs/serialization/performance/performance_iterators_base64.cpp b/src/boost/libs/serialization/performance/performance_iterators_base64.cpp new file mode 100644 index 00000000..662ea6cf --- /dev/null +++ b/src/boost/libs/serialization/performance/performance_iterators_base64.cpp @@ -0,0 +1,100 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_iterators.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +#include <algorithm> +#include <list> + +#if (defined _MSC_VER) && (_MSC_VER == 1200) +# pragma warning (disable : 4786) // too long name, harmless warning +#endif + +#include <cstdlib> +#include <cstddef> // size_t + +#include <boost/config.hpp> +#ifdef BOOST_NO_STDC_NAMESPACE +namespace std{ + using ::rand; + using ::size_t; +} +#endif + +#include <boost/serialization/pfto.hpp> + +#include <boost/archive/iterators/binary_from_base64.hpp> +#include <boost/archive/iterators/base64_from_binary.hpp> +#include <boost/archive/iterators/insert_linebreaks.hpp> +#include <boost/archive/iterators/remove_whitespace.hpp> +#include <boost/archive/iterators/transform_width.hpp> + +#include "../test/test_tools.hpp" + +#include <iostream> + +template<typename CharType> +void test_base64(){ + CharType rawdata[150]; + std::size_t size = sizeof(rawdata) / sizeof(CharType); + CharType * rptr; + for(rptr = rawdata + size; rptr-- > rawdata;) + *rptr = std::rand(); + + // convert to base64 + typedef std::list<CharType> text_base64_type; + text_base64_type text_base64; + + typedef + boost::archive::iterators::insert_linebreaks< + boost::archive::iterators::base64_from_binary< + boost::archive::iterators::transform_width< + CharType * + ,6 + ,sizeof(CharType) * 8 + > + > + ,72 + > + translate_out; + + std::copy( + translate_out(BOOST_MAKE_PFTO_WRAPPER(static_cast<CharType *>(rawdata))), + translate_out(BOOST_MAKE_PFTO_WRAPPER(rawdata + size)), + std::back_inserter(text_base64) + ); + + // convert from base64 to binary and compare with the original + typedef + boost::archive::iterators::transform_width< + boost::archive::iterators::binary_from_base64< + boost::archive::iterators::remove_whitespace< + BOOST_DEDUCED_TYPENAME text_base64_type::iterator + > + >, + sizeof(CharType) * 8, + 6 + > translate_in; + + BOOST_CHECK( + std::equal( + rawdata, + rawdata + size, + translate_in(BOOST_MAKE_PFTO_WRAPPER(text_base64.begin())) + ) + ); + +} + +int +test_main( int argc, char* argv[] ) +{ + test_base64<char>(); + #ifndef BOOST_NO_CWCHAR + test_base64<wchar_t>(); + #endif + return EXIT_SUCCESS; +} diff --git a/src/boost/libs/serialization/performance/performance_no_rtti.cpp b/src/boost/libs/serialization/performance/performance_no_rtti.cpp new file mode 100644 index 00000000..bebafe78 --- /dev/null +++ b/src/boost/libs/serialization/performance/performance_no_rtti.cpp @@ -0,0 +1,222 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_no_rtti.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// note: this program tests the inter-operability of different +// extended typeinfo systems. In this example, one class is +// identified using the default RTTI while the other uses a custom +// system based on the export key. +// +// As this program uses RTTI for one of the types, the test will fail +// on a system for which RTTI is not enabled or not existent. + +#include <fstream> + +#include <cstdio> // remove +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include <boost/static_assert.hpp> +#include <boost/type_traits/is_same.hpp> + +#include <boost/archive/archive_exception.hpp> +#include "../test/test_tools.hpp" +#include <boost/preprocessor/stringize.hpp> +// #include <boost/preprocessor/cat.hpp> +// the following fails with (only!) gcc 3.4 +// #include BOOST_PP_STRINGIZE(BOOST_PP_CAT(../test/,BOOST_ARCHIVE_TEST)) +// just copy over the files from the test directory +#include BOOST_PP_STRINGIZE(BOOST_ARCHIVE_TEST) + +#include <boost/serialization/nvp.hpp> +#include <boost/serialization/base_object.hpp> +#include <boost/serialization/export.hpp> +#include <boost/serialization/type_info_implementation.hpp> +#include <boost/serialization/extended_type_info_no_rtti.hpp> + +class polymorphic_base +{ + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive & /* ar */, const unsigned int /* file_version */){ + } +public: + virtual const char * get_key() const = 0; + virtual ~polymorphic_base(){}; +}; + +BOOST_IS_ABSTRACT(polymorphic_base) +BOOST_CLASS_TYPE_INFO( + polymorphic_base, + extended_type_info_no_rtti<polymorphic_base> +) +// note: types which use ...no_rtti MUST be exported +BOOST_CLASS_EXPORT(polymorphic_base) + +class polymorphic_derived1 : public polymorphic_base +{ + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive &ar, const unsigned int /* file_version */){ + ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(polymorphic_base); + } +public: + virtual const char * get_key() const ; +}; + +BOOST_CLASS_TYPE_INFO( + polymorphic_derived1, + extended_type_info_no_rtti<polymorphic_derived1> +) +BOOST_CLASS_EXPORT(polymorphic_derived1) + +const char * polymorphic_derived1::get_key() const { + const boost::serialization::extended_type_info *eti + = boost::serialization::type_info_implementation<polymorphic_derived1> + ::type::get_instance(); + return eti->get_key(); +} + +class polymorphic_derived2 : public polymorphic_base +{ + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive &ar, const unsigned int /* file_version */){ + ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(polymorphic_base); + } +public: + virtual const char * get_key() const ; +}; + +// note the mixing of type_info systems is supported. +BOOST_CLASS_TYPE_INFO( + polymorphic_derived2, + boost::serialization::extended_type_info_typeid<polymorphic_derived2> +) + +BOOST_CLASS_EXPORT(polymorphic_derived2) + +const char * polymorphic_derived2::get_key() const { + // use the exported key as the identifier + const boost::serialization::extended_type_info *eti + = boost::serialization::type_info_implementation<polymorphic_derived2> + ::type::get_instance(); + return eti->get_key(); +} + +// save derived polymorphic class +void save_derived(const char *testfile) +{ + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + + polymorphic_derived1 *rd1 = new polymorphic_derived1; + polymorphic_derived2 *rd2 = new polymorphic_derived2; + + oa << BOOST_SERIALIZATION_NVP(rd1); + oa << BOOST_SERIALIZATION_NVP(rd2); + + // the above opereration registers the derived classes as a side + // effect. Hence, instances can now be correctly serialized through + // a base class pointer. + polymorphic_base *rb1 = rd1; + polymorphic_base *rb2 = rd2; + oa << BOOST_SERIALIZATION_NVP(rb1); + oa << BOOST_SERIALIZATION_NVP(rb2); + + delete rd1; + delete rd2; +} + +// save derived polymorphic class +void load_derived(const char *testfile) +{ + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + + polymorphic_derived1 *rd1 = NULL; + polymorphic_derived2 *rd2 = NULL; + + ia >> BOOST_SERIALIZATION_NVP(rd1); + + BOOST_CHECK_MESSAGE( + boost::serialization::type_info_implementation<polymorphic_derived1> + ::type::get_instance() + == boost::serialization::type_info_implementation<polymorphic_derived1> + ::type::get_derived_extended_type_info(*rd1), + "restored pointer d1 not of correct type" + ); + + ia >> BOOST_SERIALIZATION_NVP(rd2); + + BOOST_CHECK_MESSAGE( + boost::serialization::type_info_implementation<polymorphic_derived2> + ::type::get_instance() + == boost::serialization::type_info_implementation<polymorphic_derived2> + ::type::get_derived_extended_type_info(*rd2), + "restored pointer d2 not of correct type" + ); + + polymorphic_base *rb1 = NULL; + polymorphic_base *rb2 = NULL; + + // the above opereration registers the derived classes as a side + // effect. Hence, instances can now be correctly serialized through + // a base class pointer. + ia >> BOOST_SERIALIZATION_NVP(rb1); + + BOOST_CHECK_MESSAGE( + rb1 == dynamic_cast<polymorphic_base *>(rd1), + "serialized pointers not correctly restored" + ); + + BOOST_CHECK_MESSAGE( + boost::serialization::type_info_implementation<polymorphic_derived1> + ::type::get_instance() + == boost::serialization::type_info_implementation<polymorphic_base> + ::type::get_derived_extended_type_info(*rb1), + "restored pointer b1 not of correct type" + ); + + ia >> BOOST_SERIALIZATION_NVP(rb2); + + BOOST_CHECK_MESSAGE( + rb2 == dynamic_cast<polymorphic_base *>(rd2), + "serialized pointers not correctly restored" + ); + + BOOST_CHECK_MESSAGE( + boost::serialization::type_info_implementation<polymorphic_derived2> + ::type::get_instance() + == boost::serialization::type_info_implementation<polymorphic_base> + ::type::get_derived_extended_type_info(*rb2), + "restored pointer b2 not of correct type" + ); + + delete rb1; + delete rb2; +} + +int +test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + + BOOST_REQUIRE(NULL != testfile); + + save_derived(testfile); + load_derived(testfile); + + std::remove(testfile); + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/performance/performance_polymorphic.cpp b/src/boost/libs/serialization/performance/performance_polymorphic.cpp new file mode 100644 index 00000000..50bc21be --- /dev/null +++ b/src/boost/libs/serialization/performance/performance_polymorphic.cpp @@ -0,0 +1,104 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_polymorphic.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <fstream> + +#include <cstdio> // remove +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include "../test/test_tools.hpp" + +#if !defined(BOOST_ARCHIVE_TEST) +#define BOOST_ARCHIVE_TEST polymorphic_text_archive.hpp +#endif + +// the following is to ensure that when one of the libraries changes +// BJAM rebuilds and relinks the test. +/* +#include "polymorphic_text_archive.hpp" +#include "polymorphic_text_warchive.hpp" +#include "polymorphic_binary_archive.hpp" +#include "polymorphic_xml_archive.hpp" +#include "polymorphic_xml_warchive.hpp" +*/ + +#include <boost/preprocessor/stringize.hpp> +// #include <boost/preprocessor/cat.hpp> +// the following fails with (only!) gcc 3.4 +// #include BOOST_PP_STRINGIZE(BOOST_PP_CAT(../test/,BOOST_ARCHIVE_TEST)) +// just copy over the files from the test directory +#include BOOST_PP_STRINGIZE(BOOST_ARCHIVE_TEST) + +#include <boost/archive/polymorphic_oarchive.hpp> +#include <boost/archive/polymorphic_iarchive.hpp> + +#include <boost/serialization/nvp.hpp> +#include "../test/test_polymorphic_A.hpp" + +int test_main(int /* argc */, char * /* argv */ []) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + const data d; + data d1; + // test using using polymorphic interface + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa_implementation(os); + boost::archive::polymorphic_oarchive & oa_interface = oa_implementation; + oa_interface << BOOST_SERIALIZATION_NVP(d); + } + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia_implementation(is); + boost::archive::polymorphic_iarchive & ia_interface = ia_implementation; + ia_interface >> BOOST_SERIALIZATION_NVP(d1); + } + BOOST_CHECK(d == d1); + std::remove(testfile); + + // test using using polymorphic implementation. + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa_implementation(os); + oa_implementation << BOOST_SERIALIZATION_NVP(d); + } + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia_implementation(is); + ia_implementation >> BOOST_SERIALIZATION_NVP(d1); + } + BOOST_CHECK(d == d1); + std::remove(testfile); + + // test using using polymorphic implementation. + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + boost::archive::polymorphic_oarchive * oa_implementation + = new test_oarchive(os); + *oa_implementation << BOOST_SERIALIZATION_NVP(d); + delete oa_implementation; + } + { + test_istream is(testfile, TEST_STREAM_FLAGS); + boost::archive::polymorphic_iarchive * ia_implementation + = new test_iarchive(is); + *ia_implementation >> BOOST_SERIALIZATION_NVP(d1); + delete ia_implementation; + } + BOOST_CHECK(d == d1); + std::remove(testfile); + return EXIT_SUCCESS; +} diff --git a/src/boost/libs/serialization/performance/performance_simple_class.cpp b/src/boost/libs/serialization/performance/performance_simple_class.cpp new file mode 100644 index 00000000..3f936078 --- /dev/null +++ b/src/boost/libs/serialization/performance/performance_simple_class.cpp @@ -0,0 +1,55 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_simple_class.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +// invoke header for a custom archive test. + +#include <fstream> + +#include <cstdio> // remove +#include <boost/config.hpp> + +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include "../test/test_tools.hpp" +#include <boost/preprocessor/stringize.hpp> +// #include <boost/preprocessor/cat.hpp> +// the following fails with (only!) gcc 3.4 +// #include BOOST_PP_STRINGIZE(BOOST_PP_CAT(../test/,BOOST_ARCHIVE_TEST)) +// just copy over the files from the test directory +#include BOOST_PP_STRINGIZE(BOOST_ARCHIVE_TEST) + +#include <boost/serialization/nvp.hpp> +#include "../test/A.hpp" + +int +test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + A a, a1; + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("a", a); + } + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("a", a1); + } + BOOST_CHECK_EQUAL(a, a1); + std::remove(testfile); + return (a == a1) ? EXIT_SUCCESS : EXIT_SUCCESS; +} diff --git a/src/boost/libs/serialization/performance/performance_utf8_codecvt.cpp b/src/boost/libs/serialization/performance/performance_utf8_codecvt.cpp new file mode 100644 index 00000000..2562f4a7 --- /dev/null +++ b/src/boost/libs/serialization/performance/performance_utf8_codecvt.cpp @@ -0,0 +1,248 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_utf8_codecvt.cpp + +// (C) Copyright 2002-4 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +#include <algorithm> +#include <fstream> +#include <iostream> +#include <iterator> +#include <locale> +#include <vector> +#include <string> + +#include <cstddef> // size_t +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::size_t; +} // namespace std +#endif + +#include <cwchar> +#ifdef BOOST_NO_STDC_NAMESPACE +namespace std{ using ::wcslen; } +#endif + +#include "../test/test_tools.hpp" +#include <boost/archive/iterators/istream_iterator.hpp> +#include <boost/archive/iterators/ostream_iterator.hpp> + +#include <boost/archive/add_facet.hpp> +#include <boost/archive/detail/utf8_codecvt_facet.hpp> + +template<std::size_t s> +struct test_data +{ + static unsigned char utf8_encoding[]; + static wchar_t wchar_encoding[]; +}; + +template<> +unsigned char test_data<2>::utf8_encoding[] = { + 0x01, + 0x7f, + 0xc2, 0x80, + 0xdf, 0xbf, + 0xe0, 0xa0, 0x80, + 0xe7, 0xbf, 0xbf +}; + +template<> +wchar_t test_data<2>::wchar_encoding[] = { + 0x0001, + 0x007f, + 0x0080, + 0x07ff, + 0x0800, + 0x7fff +}; + +template<> +unsigned char test_data<4>::utf8_encoding[] = { + 0x01, + 0x7f, + 0xc2, 0x80, + 0xdf, 0xbf, + 0xe0, 0xa0, 0x80, + 0xef, 0xbf, 0xbf, + 0xf0, 0x90, 0x80, 0x80, + 0xf4, 0x8f, 0xbf, 0xbf, + 0xf7, 0xbf, 0xbf, 0xbf, + 0xf8, 0x88, 0x80, 0x80, 0x80, + 0xfb, 0xbf, 0xbf, 0xbf, 0xbf, + 0xfc, 0x84, 0x80, 0x80, 0x80, 0x80, + 0xfd, 0xbf, 0xbf, 0xbf, 0xbf, 0xbf +}; + +template<> +wchar_t test_data<4>::wchar_encoding[] = { + 0x00000001, + 0x0000007f, + 0x00000080, + 0x000007ff, + 0x00000800, + 0x0000ffff, + 0x00010000, + 0x0010ffff, + 0x001fffff, + 0x00200000, + 0x03ffffff, + 0x04000000, + 0x7fffffff +}; + +int +test_main(int /* argc */, char * /* argv */[]) { + std::locale old_loc; + std::locale * utf8_locale + = boost::archive::add_facet( + old_loc, + new boost::archive::detail::utf8_codecvt_facet + ); + + typedef char utf8_t; + typedef test_data<sizeof(wchar_t)> td; + + // Send our test UTF-8 data to file + { + std::ofstream ofs; + ofs.open("test.dat", std::ios::binary); + std::copy( + td::utf8_encoding, + #if ! defined(__BORLANDC__) + // borland 5.60 complains about this + td::utf8_encoding + sizeof(td::utf8_encoding) / sizeof(unsigned char), + #else + // so use this instead + td::utf8_encoding + 12, + #endif + boost::archive::iterators::ostream_iterator<utf8_t>(ofs) + ); + } + + // Read the test data back in, converting to UCS-4 on the way in + std::vector<wchar_t> from_file; + { + std::wifstream ifs; + ifs.imbue(*utf8_locale); + ifs.open("test.dat"); + + wchar_t item = 0; + // note can't use normal vector from iterator constructor because + // dinkumware doesn't have it. + for(;;){ + item = ifs.get(); + if(item == WEOF) + break; + //ifs >> item; + //if(ifs.eof()) + // break; + from_file.push_back(item); + } + } + + // compare the data read back in with the orginal + #if ! defined(__BORLANDC__) + // borland 5.60 complains about this + BOOST_CHECK(from_file.size() == sizeof(td::wchar_encoding)/sizeof(wchar_t)); + #else + // so use this instead + BOOST_CHECK(from_file.size() == 6); + #endif + + BOOST_CHECK(std::equal(from_file.begin(), from_file.end(), td::wchar_encoding)); + + // Send the UCS4_data back out, converting to UTF-8 + { + std::wofstream ofs; + ofs.imbue(*utf8_locale); + ofs.open("test2.dat"); + std::copy( + from_file.begin(), + from_file.end(), + boost::archive::iterators::ostream_iterator<wchar_t>(ofs) + ); + } + + // Make sure that both files are the same + { + typedef boost::archive::iterators::istream_iterator<utf8_t> is_iter; + is_iter end_iter; + + std::ifstream ifs1("test.dat"); + is_iter it1(ifs1); + std::vector<utf8_t> data1; + std::copy(it1, end_iter, std::back_inserter(data1)); + + std::ifstream ifs2("test2.dat"); + is_iter it2(ifs2); + std::vector<utf8_t> data2; + std::copy(it2, end_iter, std::back_inserter(data2)); + + BOOST_CHECK(data1 == data2); + } + + // some libraries have trouble that only shows up with longer strings + + wchar_t * test3_data = L"\ + <?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"yes\" ?>\ + <!DOCTYPE boost_serialization>\ + <boost_serialization signature=\"serialization::archive\" version=\"3\">\ + <a class_id=\"0\" tracking_level=\"0\">\ + <b>1</b>\ + <f>96953204</f>\ + <g>177129195</g>\ + <l>1</l>\ + <m>5627</m>\ + <n>23010</n>\ + <o>7419</o>\ + <p>16212</p>\ + <q>4086</q>\ + <r>2749</r>\ + <c>-33</c>\ + <s>124</s>\ + <t>28</t>\ + <u>32225</u>\ + <v>17543</v>\ + <w>0.84431422</w>\ + <x>1.0170664757130923</x>\ + <y>tjbx</y>\ + <z>cuwjentqpkejp</z>\ + </a>\ + </boost_serialization>\ + "; + + // Send the UCS4_data back out, converting to UTF-8 + std::size_t l = std::wcslen(test3_data); + { + std::wofstream ofs; + ofs.imbue(*utf8_locale); + ofs.open("test3.dat"); + std::copy( + test3_data, + test3_data + l, + boost::archive::iterators::ostream_iterator<wchar_t>(ofs) + ); + } + + // Make sure that both files are the same + { + std::wifstream ifs; + ifs.imbue(*utf8_locale); + ifs.open("test3.dat"); + BOOST_CHECK( + std::equal( + test3_data, + test3_data + l, + boost::archive::iterators::istream_iterator<wchar_t>(ifs) + ) + ); + } + + delete utf8_locale; + return EXIT_SUCCESS; +} diff --git a/src/boost/libs/serialization/performance/performance_vector.cpp b/src/boost/libs/serialization/performance/performance_vector.cpp new file mode 100644 index 00000000..f415c6ea --- /dev/null +++ b/src/boost/libs/serialization/performance/performance_vector.cpp @@ -0,0 +1,70 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_vector.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <fstream> + +#include <cstdio> // remove +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include "../test/test_tools.hpp" +#include <boost/preprocessor/stringize.hpp> +// #include <boost/preprocessor/cat.hpp> +// the following fails with (only!) gcc 3.4 +// #include BOOST_PP_STRINGIZE(BOOST_PP_CAT(../test/,BOOST_ARCHIVE_TEST)) +// just copy over the files from the test directory +#include BOOST_PP_STRINGIZE(BOOST_ARCHIVE_TEST) +#include <boost/serialization/vector.hpp> + +#include "../test/A.hpp" + +template <class T> +int test_vector(T) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + // test array of objects + std::vector<T> avector; + avector.push_back(T()); + avector.push_back(T()); + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("avector", avector); + } + std::vector<T> avector1; + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("avector", avector1); + } + BOOST_CHECK(avector == avector1); + std::remove(testfile); + return EXIT_SUCCESS; +} + +int test_main( int /* argc */, char* /* argv */[] ) +{ + int res = test_vector(A()); + // test an int vector for which optimized versions should be available + if (res == EXIT_SUCCESS) + res = test_vector(0); + // test a bool vector + if (res == EXIT_SUCCESS) + res = test_vector(false); + return res; +} + +// EOF diff --git a/src/boost/libs/serialization/performance/polymorphic_array_binary_archive.hpp b/src/boost/libs/serialization/performance/polymorphic_array_binary_archive.hpp new file mode 100644 index 00000000..5097433a --- /dev/null +++ b/src/boost/libs/serialization/performance/polymorphic_array_binary_archive.hpp @@ -0,0 +1,13 @@ +// (C) Copyright 2002-4 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. +#include <boost/archive/polymorphic_binary_oarchive.hpp> +typedef boost::archive::polymorphic_binary_oarchive test_oarchive; +typedef std::ofstream test_ostream; +#include <boost/archive/polymorphic_binary_iarchive.hpp> +typedef boost::archive::polymorphic_binary_iarchive test_iarchive; +typedef std::ifstream test_istream; +#define TEST_STREAM_FLAGS std::ios::binary diff --git a/src/boost/libs/serialization/performance/polymorphic_binary_archive.hpp b/src/boost/libs/serialization/performance/polymorphic_binary_archive.hpp new file mode 100644 index 00000000..5097433a --- /dev/null +++ b/src/boost/libs/serialization/performance/polymorphic_binary_archive.hpp @@ -0,0 +1,13 @@ +// (C) Copyright 2002-4 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. +#include <boost/archive/polymorphic_binary_oarchive.hpp> +typedef boost::archive::polymorphic_binary_oarchive test_oarchive; +typedef std::ofstream test_ostream; +#include <boost/archive/polymorphic_binary_iarchive.hpp> +typedef boost::archive::polymorphic_binary_iarchive test_iarchive; +typedef std::ifstream test_istream; +#define TEST_STREAM_FLAGS std::ios::binary diff --git a/src/boost/libs/serialization/performance/polymorphic_text_archive.hpp b/src/boost/libs/serialization/performance/polymorphic_text_archive.hpp new file mode 100644 index 00000000..c8184b15 --- /dev/null +++ b/src/boost/libs/serialization/performance/polymorphic_text_archive.hpp @@ -0,0 +1,13 @@ +// (C) Copyright 2002-4 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. +#include <boost/archive/polymorphic_text_oarchive.hpp> +typedef boost::archive::polymorphic_text_oarchive test_oarchive; +typedef std::ofstream test_ostream; +#include <boost/archive/polymorphic_text_iarchive.hpp> +typedef boost::archive::polymorphic_text_iarchive test_iarchive; +typedef std::ifstream test_istream; +#define TEST_STREAM_FLAGS (std::ios_base::openmode)0 diff --git a/src/boost/libs/serialization/performance/polymorphic_text_warchive.hpp b/src/boost/libs/serialization/performance/polymorphic_text_warchive.hpp new file mode 100644 index 00000000..4a5774c8 --- /dev/null +++ b/src/boost/libs/serialization/performance/polymorphic_text_warchive.hpp @@ -0,0 +1,18 @@ +// (C) Copyright 2002-4 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. +#include <boost/config.hpp> +#ifdef BOOST_NO_STD_WSTREAMBUF +#error "wide char i/o not supported on this platform" +#else +#include <boost/archive/polymorphic_text_woarchive.hpp> +typedef boost::archive::polymorphic_text_woarchive test_oarchive; +typedef std::wofstream test_ostream; +#include <boost/archive/polymorphic_text_wiarchive.hpp> +typedef boost::archive::polymorphic_text_wiarchive test_iarchive; +typedef std::wifstream test_istream; +#define TEST_STREAM_FLAGS (std::ios_base::openmode)0 +#endif diff --git a/src/boost/libs/serialization/performance/polymorphic_xml_archive.hpp b/src/boost/libs/serialization/performance/polymorphic_xml_archive.hpp new file mode 100644 index 00000000..849d1a02 --- /dev/null +++ b/src/boost/libs/serialization/performance/polymorphic_xml_archive.hpp @@ -0,0 +1,13 @@ +// (C) Copyright 2002-4 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. +#include <boost/archive/polymorphic_xml_oarchive.hpp> +typedef boost::archive::polymorphic_xml_oarchive test_oarchive; +typedef std::ofstream test_ostream; +#include <boost/archive/polymorphic_xml_iarchive.hpp> +typedef boost::archive::polymorphic_xml_iarchive test_iarchive; +typedef std::ifstream test_istream; +#define TEST_STREAM_FLAGS (std::ios_base::openmode)0 diff --git a/src/boost/libs/serialization/performance/polymorphic_xml_warchive.hpp b/src/boost/libs/serialization/performance/polymorphic_xml_warchive.hpp new file mode 100644 index 00000000..1f5c5ff0 --- /dev/null +++ b/src/boost/libs/serialization/performance/polymorphic_xml_warchive.hpp @@ -0,0 +1,13 @@ +// (C) Copyright 2002-4 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. +#include <boost/archive/polymorphic_xml_woarchive.hpp> +typedef boost::archive::polymorphic_xml_woarchive test_oarchive; +typedef std::wofstream test_ostream; +#include <boost/archive/polymorphic_xml_wiarchive.hpp> +typedef boost::archive::polymorphic_xml_wiarchive test_iarchive; +typedef std::wifstream test_istream; +#define TEST_STREAM_FLAGS (std::ios_base::openmode)0 diff --git a/src/boost/libs/serialization/performance/portable_binary_archive.hpp b/src/boost/libs/serialization/performance/portable_binary_archive.hpp new file mode 100644 index 00000000..c1377c92 --- /dev/null +++ b/src/boost/libs/serialization/performance/portable_binary_archive.hpp @@ -0,0 +1,22 @@ +// (C) Copyright 2002-4 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history.// file includes for testing a custom archive. +// as an example this tests the portable binary archive + +// #include output archive header +#include "../example/portable_binary_oarchive.hpp" +// define output archive class to be used +typedef portable_binary_oarchive test_oarchive; +// and corresponding stream +typedef std::ofstream test_ostream; + +// repeat the above for correspondng input archive +#include "../example/portable_binary_iarchive.hpp" +typedef portable_binary_iarchive test_iarchive; +typedef std::ifstream test_istream; + +// and stream open flags +#define TEST_STREAM_FLAGS std::ios::binary diff --git a/src/boost/libs/serialization/performance/profile.sh b/src/boost/libs/serialization/performance/profile.sh new file mode 100755 index 00000000..95ae4202 --- /dev/null +++ b/src/boost/libs/serialization/performance/profile.sh @@ -0,0 +1,39 @@ +# build and run the tests leaving the executables in place + +# (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +# Use, modification and distribution is subject to the Boost Software +# License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +# http://www.boost.org/LICENSE_1_0.txt) + +# profile.sh --toolset=gcc preserve-test-targets=on variant=profile +if test $# -eq 0 +then + echo "Usage: $0 <bjam arguments>" + echo "Typical bjam arguements are:" + echo " toolset=msvc-7.1,gcc" + echo " link=static,shared" + echo " threading=single,multi" + echo " -sBOOST_ARCHIVE_LIST=<archive name>" +else + bjam --dump-tests variant=profile preserve-test-targets=on $@ >bjam.log 2>&1 + process_jam_log --v2 <bjam.log + + # for each test directory + + for dir in \ + ../../../bin.v2/libs/serialization/performance/*/gcc*/profile \ + ../../../bin.v2/libs/serialization/performance/*/gcc*/*/profile + do + # execute test + for exe in $dir/*.exe + do + # execute the test + echo executing $exe + $exe + # copy profile to test directory + gprof $exe gmon.out >$dir/profile.txt + done + done + + library_status library_status.html links.html +fi diff --git a/src/boost/libs/serialization/performance/text_archive.hpp b/src/boost/libs/serialization/performance/text_archive.hpp new file mode 100644 index 00000000..e7e1b3ca --- /dev/null +++ b/src/boost/libs/serialization/performance/text_archive.hpp @@ -0,0 +1,14 @@ +// (C) Copyright 2002-4 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. +// text_archive +#include <boost/archive/text_oarchive.hpp> +typedef boost::archive::text_oarchive test_oarchive; +typedef std::ofstream test_ostream; +#include <boost/archive/text_iarchive.hpp> +typedef boost::archive::text_iarchive test_iarchive; +typedef std::ifstream test_istream; +#define TEST_STREAM_FLAGS (std::ios_base::openmode)0 diff --git a/src/boost/libs/serialization/performance/text_warchive.hpp b/src/boost/libs/serialization/performance/text_warchive.hpp new file mode 100644 index 00000000..de7dea01 --- /dev/null +++ b/src/boost/libs/serialization/performance/text_warchive.hpp @@ -0,0 +1,19 @@ +// (C) Copyright 2002-4 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. +// text_warchive +#include <boost/archive/text_woarchive.hpp> +typedef boost::archive::text_woarchive test_oarchive; +typedef std::wofstream test_ostream; +#include <boost/archive/text_wiarchive.hpp> +typedef boost::archive::text_wiarchive test_iarchive; +typedef std::wifstream test_istream; +#define TEST_STREAM_FLAGS (std::ios_base::openmode)0 + + + + + diff --git a/src/boost/libs/serialization/performance/xml/Jamfile.v2 b/src/boost/libs/serialization/performance/xml/Jamfile.v2 new file mode 100644 index 00000000..cdd792e5 --- /dev/null +++ b/src/boost/libs/serialization/performance/xml/Jamfile.v2 @@ -0,0 +1,35 @@ +################################################################################ +# +# (C) Copyright 2010 Bryce Lelbach +# +# Use, modification and distribution is subject to the Boost Software License, +# Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +# http://www.boost.org/LICENSE_1_0.txt) +# +################################################################################ + +project bsl-xml-benchmark ; + +exe int4_test : int4_test.cpp + : <toolset>gcc:<linkflags>"-lrt -lboost_serialization" ; + +exe int16_test : int16_test.cpp + : <toolset>gcc:<linkflags>"-lrt -lboost_serialization" ; + +exe int64_test : int64_test.cpp + : <toolset>gcc:<linkflags>"-lrt -lboost_serialization" ; + +exe int256_test : int256_test.cpp + : <toolset>gcc:<linkflags>"-lrt -lboost_serialization" ; + +exe string4_test : string4_test.cpp + : <toolset>gcc:<linkflags>"-lrt -lboost_serialization" ; + +exe string16_test : string16_test.cpp + : <toolset>gcc:<linkflags>"-lrt -lboost_serialization" ; + +exe string64_test : string64_test.cpp + : <toolset>gcc:<linkflags>"-lrt -lboost_serialization" ; + +exe string256_test : string256_test.cpp + : <toolset>gcc:<linkflags>"-lrt -lboost_serialization" ; diff --git a/src/boost/libs/serialization/performance/xml/harness.hpp b/src/boost/libs/serialization/performance/xml/harness.hpp new file mode 100644 index 00000000..8955be21 --- /dev/null +++ b/src/boost/libs/serialization/performance/xml/harness.hpp @@ -0,0 +1,188 @@ +/* /libs/serialization/xml_performance/harness.hpp ***************************** + +(C) Copyright 2010 Bryce Lelbach + +Use, modification and distribution is subject to the Boost Software License, +Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +http://www.boost.org/LICENSE_1_0.txt) + +*******************************************************************************/ + +#if !defined(BOOST_SERIALIZATION_XML_PERFORMANCE_HARNESS_HPP) +#define BOOST_SERIALIZATION_XML_PERFORMANCE_HARNESS_HPP + +// MS compatible compilers support #pragma once +#if defined(_MSC_VER) + # pragma once +#endif + +#include <cassert> +#include <cstdio> + +#include <string> +#include <fstream> +#include <iostream> +#include <utility> + +#include <boost/config.hpp> + +#if defined(BOOST_NO_STDC_NAMESPACE) + namespace std { + using ::remove; + } +#endif + +#include <boost/uuid/uuid.hpp> +#include <boost/uuid/uuid_io.hpp> +#include <boost/uuid/random_generator.hpp> + +#include <boost/functional/hash.hpp> + +#include <boost/utility/enable_if.hpp> + +#include <boost/type_traits/is_integral.hpp> + +#include <boost/archive/xml_iarchive.hpp> +#include <boost/archive/xml_oarchive.hpp> + +#include <boost/archive/archive_exception.hpp> + +#include "high_resolution_timer.hpp" // from /libs/spirit/optimization + +#include "node.hpp" // includes macro.hpp + +namespace boost { +namespace archive { +namespace xml { + +template<typename T> T random (void); + +template<typename T> T +random (void) { + using namespace boost::uuids; + + hash<uuid> hash; + basic_random_generator<mt19937> gen; + + return hash(gen()); +} + +template<> std::string +random<std::string> (void) { + using namespace boost::uuids; + + basic_random_generator<mt19937> gen; + uuid u = gen(); + + return to_string(u); +} + +template<typename T> std::string +save_archive (T const& s) { + std::string fn = random<std::string>() + + "-" BOOST_PP_STRINGIZE(BSL_TYPE) + BOOST_PP_STRINGIZE(BSL_EXP(BSL_NODE_MAX, BSL_DEPTH)) + ".xml" + ; + + std::ofstream ofs(fn.c_str()); + + assert(ofs.good()); + + xml_oarchive oa(ofs); + oa << BOOST_SERIALIZATION_NVP(s); + + ofs.close(); + return fn; +} + +template<typename T> std::pair<double, T> +restore_archive (std::string fn) { + std::ifstream ifs(fn.c_str()); + T s; + + assert(ifs.good()); + + high_resolution_timer u; + + xml_iarchive ia(ifs); + ia >> BOOST_SERIALIZATION_NVP(s); + + ifs.close(); + return std::pair<double, T>(u.elapsed(), s); +} + +class result_set_exception: public virtual archive_exception { + public: + enum exception_code { + invalid_archive_metadata + }; + + result_set_exception (exception_code c = invalid_archive_metadata){ } + + virtual const char* what() const throw() { + const char *msg = ""; + + switch (code) { + case invalid_archive_metadata: + msg = "result set was not created on this system"; + default: + archive_exception::what(); + } + + return msg; + } +}; + +struct entry { + std::string type; + std::size_t size; + double data; + + template<class ARC> + void serialize (ARC& ar, const unsigned int) { + ar & BOOST_SERIALIZATION_NVP(type) + & BOOST_SERIALIZATION_NVP(size) + & BOOST_SERIALIZATION_NVP(data) + ; + } + + entry (void) { } + + entry (std::string type, std::size_t size, double data): + type(type), size(size), data(data) { } +}; + +struct result_set { + std::string compiler; + std::string platform; + std::list<entry> entries; + + template<class ARC> + void serialize (ARC& ar, const unsigned int) { + ar & BOOST_SERIALIZATION_NVP(compiler) + & BOOST_SERIALIZATION_NVP(platform) + & BOOST_SERIALIZATION_NVP(entries) + ; + + if ( (compiler != BOOST_COMPILER) + || (platform != BOOST_PLATFORM)) + throw result_set_exception(); + } + + result_set (void): + compiler(BOOST_COMPILER), + platform(BOOST_PLATFORM) { } + + result_set (std::list<entry> entries): + compiler(BOOST_COMPILER), + platform(BOOST_PLATFORM), + entries(entries) { } +}; + +} // xml +} // archive +} // boost + +#endif // BOOST_SERIALIZATION_XML_PERFORMANCE_HARNESS_HPP + diff --git a/src/boost/libs/serialization/performance/xml/high_resolution_timer.hpp b/src/boost/libs/serialization/performance/xml/high_resolution_timer.hpp new file mode 100644 index 00000000..afa5495d --- /dev/null +++ b/src/boost/libs/serialization/performance/xml/high_resolution_timer.hpp @@ -0,0 +1,489 @@ +// Copyright (c) 2005-2010 Hartmut Kaiser +// Copyright (c) 2009 Edward Grace +// +// Distributed under the Boost Software License, Version 1.0. (See accompanying +// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) + +#if !defined(HIGH_RESOLUTION_TIMER_MAR_24_2008_1222PM) +#define HIGH_RESOLUTION_TIMER_MAR_24_2008_1222PM + +#include <boost/config.hpp> +#include <boost/throw_exception.hpp> + +#if defined(BOOST_HAS_UNISTD_H) +#include <unistd.h> +#endif +#include <time.h> +#include <stdexcept> +#include <limits> + +#if defined(BOOST_WINDOWS) + +#include <windows.h> + +namespace boost { +namespace archive { +namespace xml { + /////////////////////////////////////////////////////////////////////////////// + // + // high_resolution_timer + // A timer object measures elapsed time. + // CAUTION: Windows only! + // + /////////////////////////////////////////////////////////////////////////////// + class high_resolution_timer + { + public: + high_resolution_timer() + { + restart(); + } + + high_resolution_timer(double t) + { + LARGE_INTEGER frequency; + if (!QueryPerformanceFrequency(&frequency)) + boost::throw_exception(std::runtime_error("Couldn't acquire frequency")); + + start_time.QuadPart = (LONGLONG)(t * frequency.QuadPart); + } + + high_resolution_timer(high_resolution_timer const& rhs) + : start_time(rhs.start_time) + { + } + + static double now() + { + SYSTEMTIME st; + GetSystemTime(&st); + + FILETIME ft; + SystemTimeToFileTime(&st, &ft); + + LARGE_INTEGER now; + now.LowPart = ft.dwLowDateTime; + now.HighPart = ft.dwHighDateTime; + + // FileTime is in 100ns increments, result needs to be in [s] + return now.QuadPart * 1e-7; + } + + void restart() + { + if (!QueryPerformanceCounter(&start_time)) + boost::throw_exception(std::runtime_error("Couldn't initialize start_time")); + } + double elapsed() const // return elapsed time in seconds + { + LARGE_INTEGER now; + if (!QueryPerformanceCounter(&now)) + boost::throw_exception(std::runtime_error("Couldn't get current time")); + + LARGE_INTEGER frequency; + if (!QueryPerformanceFrequency(&frequency)) + boost::throw_exception(std::runtime_error("Couldn't acquire frequency")); + + return double(now.QuadPart - start_time.QuadPart) / frequency.QuadPart; + } + + double elapsed_max() const // return estimated maximum value for elapsed() + { + LARGE_INTEGER frequency; + if (!QueryPerformanceFrequency(&frequency)) + boost::throw_exception(std::runtime_error("Couldn't acquire frequency")); + + return double((std::numeric_limits<LONGLONG>::max)() - start_time.QuadPart) / + double(frequency.QuadPart); + } + + double elapsed_min() const // return minimum value for elapsed() + { + LARGE_INTEGER frequency; + if (!QueryPerformanceFrequency(&frequency)) + boost::throw_exception(std::runtime_error("Couldn't acquire frequency")); + + return 1.0 / frequency.QuadPart; + } + + private: + LARGE_INTEGER start_time; + }; + +} // xml +} // archive +} // boost + +#elif defined(_POSIX_TIMERS) && _POSIX_TIMERS > 0 && defined(_POSIX_THREAD_CPUTIME) + +#if _POSIX_THREAD_CPUTIME > 0 // timer always supported + +namespace boost { +namespace archive { +namespace xml { + + /////////////////////////////////////////////////////////////////////////////// + // + // high_resolution_timer + // A timer object measures elapsed time. + // + /////////////////////////////////////////////////////////////////////////////// + class high_resolution_timer + { + public: + high_resolution_timer() + { + start_time.tv_sec = 0; + start_time.tv_nsec = 0; + + restart(); + } + + high_resolution_timer(double t) + { + start_time.tv_sec = time_t(t); + start_time.tv_nsec = (t - start_time.tv_sec) * 1e9; + } + + high_resolution_timer(high_resolution_timer const& rhs) + : start_time(rhs.start_time) + { + } + + static double now() + { + timespec now; + if (-1 == clock_gettime(CLOCK_REALTIME, &now)) + boost::throw_exception(std::runtime_error("Couldn't get current time")); + return double(now.tv_sec) + double(now.tv_nsec) * 1e-9; + } + + void restart() + { + if (-1 == clock_gettime(CLOCK_REALTIME, &start_time)) + boost::throw_exception(std::runtime_error("Couldn't initialize start_time")); + } + double elapsed() const // return elapsed time in seconds + { + timespec now; + if (-1 == clock_gettime(CLOCK_REALTIME, &now)) + boost::throw_exception(std::runtime_error("Couldn't get current time")); + + if (now.tv_sec == start_time.tv_sec) + return double(now.tv_nsec - start_time.tv_nsec) * 1e-9; + + return double(now.tv_sec - start_time.tv_sec) + + (double(now.tv_nsec - start_time.tv_nsec) * 1e-9); + } + + double elapsed_max() const // return estimated maximum value for elapsed() + { + return double((std::numeric_limits<time_t>::max)() - start_time.tv_sec); + } + + double elapsed_min() const // return minimum value for elapsed() + { + timespec resolution; + if (-1 == clock_getres(CLOCK_REALTIME, &resolution)) + boost::throw_exception(std::runtime_error("Couldn't get resolution")); + return double(resolution.tv_sec + resolution.tv_nsec * 1e-9); + } + + private: + timespec start_time; + }; + +} // xml +} // archive +} // boost + +#else // _POSIX_THREAD_CPUTIME > 0 + +#include <boost/timer.hpp> + +// availability of high performance timers must be checked at runtime +namespace boost { +namespace archive { +namespace xml { + /////////////////////////////////////////////////////////////////////////////// + // + // high_resolution_timer + // A timer object measures elapsed time. + // + /////////////////////////////////////////////////////////////////////////////// + class high_resolution_timer + { + public: + high_resolution_timer() + : use_backup(sysconf(_SC_THREAD_CPUTIME) <= 0) + { + if (!use_backup) { + start_time.tv_sec = 0; + start_time.tv_nsec = 0; + } + restart(); + } + + high_resolution_timer(double t) + : use_backup(sysconf(_SC_THREAD_CPUTIME) <= 0) + { + if (!use_backup) { + start_time.tv_sec = time_t(t); + start_time.tv_nsec = (t - start_time.tv_sec) * 1e9; + } + } + + high_resolution_timer(high_resolution_timer const& rhs) + : use_backup(sysconf(_SC_THREAD_CPUTIME) <= 0), + start_time(rhs.start_time) + { + } + + static double now() + { + if (sysconf(_SC_THREAD_CPUTIME) <= 0) + return double(std::clock()); + + timespec now; + if (-1 == clock_gettime(CLOCK_REALTIME, &now)) + boost::throw_exception(std::runtime_error("Couldn't get current time")); + return double(now.tv_sec) + double(now.tv_nsec) * 1e-9; + } + + void restart() + { + if (use_backup) + start_time_backup.restart(); + else if (-1 == clock_gettime(CLOCK_REALTIME, &start_time)) + boost::throw_exception(std::runtime_error("Couldn't initialize start_time")); + } + double elapsed() const // return elapsed time in seconds + { + if (use_backup) + return start_time_backup.elapsed(); + + timespec now; + if (-1 == clock_gettime(CLOCK_REALTIME, &now)) + boost::throw_exception(std::runtime_error("Couldn't get current time")); + + if (now.tv_sec == start_time.tv_sec) + return double(now.tv_nsec - start_time.tv_nsec) * 1e-9; + + return double(now.tv_sec - start_time.tv_sec) + + (double(now.tv_nsec - start_time.tv_nsec) * 1e-9); + } + + double elapsed_max() const // return estimated maximum value for elapsed() + { + if (use_backup) + start_time_backup.elapsed_max(); + + return double((std::numeric_limits<time_t>::max)() - start_time.tv_sec); + } + + double elapsed_min() const // return minimum value for elapsed() + { + if (use_backup) + start_time_backup.elapsed_min(); + + timespec resolution; + if (-1 == clock_getres(CLOCK_REALTIME, &resolution)) + boost::throw_exception(std::runtime_error("Couldn't get resolution")); + return double(resolution.tv_sec + resolution.tv_nsec * 1e-9); + } + + private: + bool use_backup; + timespec start_time; + boost::timer start_time_backup; + }; + +} // xml +} // archive +} // boost + +#endif // _POSIX_THREAD_CPUTIME > 0 + +#else // !defined(BOOST_WINDOWS) && (!defined(_POSIX_TIMERS) + // || _POSIX_TIMERS <= 0 + // || !defined(_POSIX_THREAD_CPUTIME) + // || _POSIX_THREAD_CPUTIME <= 0) + +#if defined(BOOST_HAS_GETTIMEOFDAY) + +// For platforms that do not support _POSIX_TIMERS but do have +// GETTIMEOFDAY, which is still preferable to std::clock() +#include <sys/time.h> + +namespace boost { +namespace archive { +namespace xml { + + /////////////////////////////////////////////////////////////////////////// + // + // high_resolution_timer + // A timer object measures elapsed time. + // + // Implemented with gettimeofday() for platforms that support it, + // such as Darwin (OS X) but do not support the previous options. + // + // Copyright (c) 2009 Edward Grace + // + /////////////////////////////////////////////////////////////////////////// + class high_resolution_timer + { + private: + template <typename U> + static inline double unsigned_diff(const U &a, const U &b) + { + if (a > b) + return static_cast<double>(a-b); + return -static_cast<double>(b-a); + } + + // @brief Return the difference between two timeval types. + // + // @param t1 The most recent timeval. + // @param t0 The historical timeval. + // + // @return The difference between the two in seconds. + double elapsed(const timeval &t1, const timeval &t0) const + { + if (t1.tv_sec == t0.tv_sec) + return unsigned_diff(t1.tv_usec,t0.tv_usec) * 1e-6; + + // We do it this way as the result of the difference of the + // microseconds can be negative if the clock is implemented so + // that the seconds timer increases in large steps. + // + // Naive subtraction of the unsigned types and conversion to + // double can wreak havoc! + return unsigned_diff(t1.tv_sec,t0.tv_sec) + + unsigned_diff(t1.tv_usec,t0.tv_usec) * 1e-6; + } + + public: + high_resolution_timer() + { + start_time.tv_sec = 0; + start_time.tv_usec = 0; + + restart(); + } + + high_resolution_timer(double t) + { + start_time.tv_sec = time_t(t); + start_time.tv_usec = (t - start_time.tv_sec) * 1e6; + } + + high_resolution_timer(high_resolution_timer const& rhs) + : start_time(rhs.start_time) + { + } + + static double now() + { + // Under some implementations gettimeofday() will always + // return zero. If it returns anything else however then + // we accept this as evidence of an error. Note we are + // not assuming that -1 explicitly indicates the error + // condition, just that non zero is indicative of the + // error. + timeval now; + if (gettimeofday(&now, NULL)) + boost::throw_exception(std::runtime_error("Couldn't get current time")); + return double(now.tv_sec) + double(now.tv_usec) * 1e-6; + } + + void restart() + { + if (gettimeofday(&start_time, NULL)) + boost::throw_exception(std::runtime_error("Couldn't initialize start_time")); + } + + double elapsed() const // return elapsed time in seconds + { + timeval now; + if (gettimeofday(&now, NULL)) + boost::throw_exception(std::runtime_error("Couldn't get current time")); + return elapsed(now,start_time); + } + + double elapsed_max() const // return estimated maximum value for elapsed() + { + return double((std::numeric_limits<time_t>::max)() - start_time.tv_sec); + } + + double elapsed_min() const // return minimum value for elapsed() + { + // On systems without an explicit clock_getres or similar + // we can only estimate an upper bound on the resolution + // by repeatedly calling the gettimeofday function. This + // is often likely to be indicative of the true + // resolution. + timeval t0, t1; + double delta(0); + + if (gettimeofday(&t0, NULL)) + boost::throw_exception(std::runtime_error("Couldn't get resolution.")); + + // Spin around in a tight loop until we observe a change + // in the reported timer value. + do { + if (gettimeofday(&t1, NULL)) + boost::throw_exception(std::runtime_error("Couldn't get resolution.")); + delta = elapsed(t1, t0); + } while (delta <= 0.0); + + return delta; + } + + private: + timeval start_time; + }; + +} // xml +} // archive +} // boost + +#else // BOOST_HAS_GETTIMEOFDAY + +// For platforms other than Windows or Linux, or not implementing gettimeofday +// simply fall back to boost::timer +#include <boost/timer.hpp> + +namespace boost { +namespace archive { +namespace xml { + + struct high_resolution_timer + : boost::timer + { + static double now() + { + return double(std::clock()); + } + }; + +} // xml +} // archive +} // boost + + +#endif + +#endif + +#endif // HIGH_RESOLUTION_TIMER_AUG_14_2009_0425PM + +// +// $Log: high_resolution_timer.hpp,v $ +// Revision 1.4 2009/08/14 15:28:10 graceej +// * It is entirely possible for the updating clock to increment the +// * seconds and *decrement* the microseconds field. Consequently +// * when subtracting these unsigned microseconds fields a wrap-around +// * error can occur. For this reason elapsed(t1, t0) is used in a +// * similar maner to cycle.h this preserves the sign of the +// * difference. +// diff --git a/src/boost/libs/serialization/performance/xml/int16_results.xml b/src/boost/libs/serialization/performance/xml/int16_results.xml new file mode 100644 index 00000000..a3708b3d --- /dev/null +++ b/src/boost/libs/serialization/performance/xml/int16_results.xml @@ -0,0 +1,1291 @@ +<?xml version="1.0" encoding="UTF-8" standalone="yes" ?> +<!DOCTYPE boost_serialization> +<boost_serialization signature="serialization::archive" version="8"> +<results class_id="0" tracking_level="0" version="0"> + <compiler>GNU C++ version 4.5.1 20100617 (prerelease)</compiler> + <platform>linux</platform> + <entries class_id="1" tracking_level="0" version="0"> + <count>256</count> + <item_version>0</item_version> + <item class_id="2" tracking_level="0" version="0"> + <type>int</type> + <size>16</size> + <data>0.0091240829999999998</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039804419999999998</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.003975363</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0041283230000000006</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.003973201</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039916819999999999</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039507209999999999</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.003963243</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039550010000000005</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039774010000000002</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0040641210000000004</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0040065630000000003</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039576810000000002</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039339209999999999</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039280410000000002</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039456830000000002</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039237630000000003</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039022810000000001</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039720409999999999</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039302410000000001</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0040139630000000006</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.003958441</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039454820000000002</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.003940921</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039098830000000003</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039246010000000007</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039138010000000006</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039268810000000001</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039260830000000004</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039660830000000005</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039050410000000002</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039309610000000002</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039204830000000006</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039173630000000001</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039208010000000007</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039189620000000007</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039035220000000004</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039350030000000003</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039948810000000005</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039946010000000004</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039224820000000006</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039112830000000006</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.00392612</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039826410000000003</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039312010000000005</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.003906283</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0040008029999999998</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039259610000000004</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039096820000000003</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039164009999999999</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039059230000000004</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039398410000000003</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039865610000000004</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039256410000000005</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039788829999999999</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0040020799999999999</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039252410000000003</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039988810000000001</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039786029999999998</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039644430000000007</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039585210000000004</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039494420000000001</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039636020000000001</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039696430000000001</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039952010000000003</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039923210000000001</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.003981081</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039232429999999999</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039772010000000005</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0040404009999999999</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039756820000000003</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039785230000000003</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0040130030000000002</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039342810000000004</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039185610000000001</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.003929002</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039356030000000002</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039261210000000003</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039248010000000003</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039206010000000001</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.003921323</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039623610000000002</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039768010000000003</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039882810000000006</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039450430000000005</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039181229999999999</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039785210000000005</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039770420000000001</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.003920242</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0040526030000000001</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039671610000000003</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039684009999999999</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.003951001</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039216429999999998</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039896410000000004</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039810010000000005</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039498020000000005</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039298430000000006</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039901630000000006</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039274410000000003</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039447610000000006</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039199630000000003</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.003965283</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.004002121</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0040376020000000004</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.003977202</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039340830000000005</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039951610000000005</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.003941361</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039718420000000006</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039271230000000002</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039771630000000006</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039450810000000005</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039788410000000003</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.003906563</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039912430000000002</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039290410000000003</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0040306020000000003</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039789200000000004</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039774830000000004</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039634810000000005</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039378010000000003</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039205619999999998</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039250830000000002</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039660609999999999</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039749609999999999</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.003934402</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039190830000000003</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039127229999999999</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039247610000000006</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039810010000000005</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039310410000000006</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039226830000000006</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039676010000000003</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039205200000000003</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039862420000000001</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039284430000000002</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.00398292</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039506810000000002</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0040586010000000002</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039792030000000006</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0040032829999999998</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039780409999999999</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039807620000000005</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039528810000000001</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039343630000000006</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039706810000000002</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039614810000000002</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039668810000000002</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0040543630000000001</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039853600000000003</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039722410000000005</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0040198410000000006</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039786029999999998</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039824430000000004</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039788010000000006</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039784420000000004</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039569219999999999</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039798429999999829</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.003989561</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039734410000000003</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.003959522</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039615230000000006</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039729209999999999</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0040494010000000002</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.003996561</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039343630000000006</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039701229999999999</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039064010000000003</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039213620000000003</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039636419999999999</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039354030000000005</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039401610000000002</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.003979481</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039353210000000003</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039471230000000003</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039845210000000004</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0040990010000000006</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039887210000000006</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039748830000000002</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039555630000000005</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039723610000000006</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039555220000000004</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039587630000000006</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039941630000000002</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039804410000000004</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039180810000000003</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039247220000000003</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039286830000000005</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.003925001</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039934810000000001</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.003982602</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039627230000000005</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039693430000000002</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.003979481</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039772420000000006</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039774830000000004</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039840029999999999</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039316810000000002</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039705210000000003</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0040028810000000007</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039730830000000005</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0040140410000000003</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039439610000000002</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039728410000000004</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039775629999999999</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039797600000000006</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039672409999999998</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.003991802</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039799230000000007</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0040010829999999999</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039361209999999999</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039165210000000001</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0040524020000000001</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039798030000000005</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.003964721</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039675610000000005</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0040526010000000003</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039617630000000001</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0040681210000000001</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039866010000000002</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039520010000000001</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039534430000000001</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039646030000000006</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039686809999999999</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039310810000000003</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039799610000000006</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039404429999999602</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0040029610000000002</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.003971161</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039470020000000007</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039831630000000005</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.003932161</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039708410000000001</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039706020000000002</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039416830000000005</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039592830000000001</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039440410000000006</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039856819999999999</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039864810000000001</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039909230000000004</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039244409999999999</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0040034810000000006</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039812010000000002</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039719230000000005</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0040905210000000006</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039932810000000004</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039387220000000004</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039618029999999999</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0040639630000000003</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039436410000000003</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039764420000000002</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039905230000000002</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0040003629999999998</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039767610000000005</data> + </item> + <item> + <type>int</type> + <size>16</size> + <data>0.0039385219999999999</data> + </item> + </entries> +</results> diff --git a/src/boost/libs/serialization/performance/xml/int16_test.cpp b/src/boost/libs/serialization/performance/xml/int16_test.cpp new file mode 100644 index 00000000..bb633f64 --- /dev/null +++ b/src/boost/libs/serialization/performance/xml/int16_test.cpp @@ -0,0 +1,20 @@ +/* /libs/serialization/xml_performance/int25_test.cpp ************************** + +(C) Copyright 2010 Bryce Lelbach + +Use, modification and distribution is subject to the Boost Software License, +Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +http://www.boost.org/LICENSE_1_0.txt) + +*******************************************************************************/ + +#define BSL_TYPE int +#define BSL_DEPTH 2 +#define BSL_ROUNDS 256 +#define BSL_NODE_MAX 4 +#define BSL_SAVE_TMPFILE 0 + +#include "harness.hpp" + +BSL_MAIN + diff --git a/src/boost/libs/serialization/performance/xml/int256_results.xml b/src/boost/libs/serialization/performance/xml/int256_results.xml new file mode 100644 index 00000000..488ea9a6 --- /dev/null +++ b/src/boost/libs/serialization/performance/xml/int256_results.xml @@ -0,0 +1,1291 @@ +<?xml version="1.0" encoding="UTF-8" standalone="yes" ?> +<!DOCTYPE boost_serialization> +<boost_serialization signature="serialization::archive" version="8"> +<results class_id="0" tracking_level="0" version="0"> + <compiler>GNU C++ version 4.5.1 20100617 (prerelease)</compiler> + <platform>linux</platform> + <entries class_id="1" tracking_level="0" version="0"> + <count>256</count> + <item_version>0</item_version> + <item class_id="2" tracking_level="0" version="0"> + <type>int</type> + <size>256</size> + <data>0.15321624699999992</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.08650484</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.085920982000000007</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.085633820999999999</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.16989353200000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.068107577000000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.16393698700000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.151674061</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.085580072000000007</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.085237985000000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.17062496600000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.16267781100000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.16851917800000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.14782741100000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.086171551999999998</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.114132571</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.12319324500000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.110353244</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.097322675000000011</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.15796201600000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.086067782000000009</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.125855732</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.095308130999999907</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.085265061000000003</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.109543947</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.14504557000000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.14939509599999989</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.082221090999999968</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.109551042</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.12431112100000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.085782263000000011</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.15682879900000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.068575454000000008</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.15049496400000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.12869196700000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.17715746300000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.13313712599999999</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.08405491100000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.16982336199999992</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.1650644779999999</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.087539541000000012</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.144009527</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.084986318000000005</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.15154921200000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.089096928999999991</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.078815780000000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.15179225900000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.071424974000000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.17383854799999998</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.15968935400000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.15121306300000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.17404088399999995</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.14575297599999992</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.147578247</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.088792417999999929</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.13412004899999996</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.086281149000000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.10452476200000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.17052829600000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.12843396500000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.24160787</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.17276313100000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.08786999299999998</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.10957144100000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.18513253200000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.12825971899999999</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.14682889500000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.14917019100000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.13963762200000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.162242785</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.171921189</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.21192338600000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.16182439900000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.075873628999999998</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.091050645999999999</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.090728246000000012</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.16790991200000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.131269792</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.147774081</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.075707901000000008</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.085849350000000005</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.17120687700000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.18270776999999994</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.115657858</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.086130823000000009</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.08591346100000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.148075872</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.093777932000000008</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.170032617</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.078983854000000006</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.183002574</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.17499062400000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.16999298600000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.12343807900000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.17547888899999997</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.070078961000000009</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.184841536</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.089750393000000012</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.09077006</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.14565105699999992</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.17549457500000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.16971993600000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.086169903000000006</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.15882590900000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.087636622000000011</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.091248745000000006</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.17427003100000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.15880698700000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.131337537</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.17184867300000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.17884059400000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.18736676700000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.13111488800000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.10980652</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.20151995</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.10182866500000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.13558609700000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.085793494000000012</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.169369618</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.16526854600000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.172801116</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.170604694</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.085537078000000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.13368856099999993</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.13219763200000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.170200771</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.094924826000000004</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.086014382</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.101821225</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.11041902200000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.17392156399999992</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.14795049999999998</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.17319567400000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.177151848</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.17826678499999993</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.18706392999999999</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.097755478999999923</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.085452795000000012</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.17952716699999993</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.178897155</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.17744515400000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.18380319199999995</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.090120586000000003</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.20748273</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.121544734</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.097762067000000008</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.17140295499999991</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.17661355500000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.123409586</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.18124515800000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.17018973100000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.16837838000000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.090471122000000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.18274939500000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.170376201</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.086761270000000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.07082036600000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.090469033000000004</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.17457247199999992</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.085507465000000005</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.086006947</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.091171989000000009</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.087034903000000011</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.12438318900000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.091942750000000004</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.085740925000000009</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.11181491799999999</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.114592052</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.14088795500000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.11735219499999994</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.172994324</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.14173148300000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.13917877400000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.14680699700000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.10930996100000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.144352757</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.088056063000000004</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.086860233000000009</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.1702753629999999</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.086362106000000008</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.085859911000000011</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.085879831000000004</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.12267887299999991</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.098423322000000008</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.153468932</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.122094645</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.11257624400000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.160093242</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.10990803</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.16383646200000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.10992213000000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.15929886000000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.14134709300000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.08445474900000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.087441700000000011</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.085373326999999999</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.16715591000000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.151999576</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.17614413999999989</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.096750264000000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.085893666000000007</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.17629694000000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.16497436300000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.086379006000000008</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.08848594600000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.068952251000000006</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.177542798</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.12553706100000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.15891637</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.086406062000000006</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.085517463000000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.13787316499999991</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.085759060000000012</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.156784109</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.085655992</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.100888635</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.15356141700000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.15893653900000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.17356975800000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.15669519600000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.14556728399999996</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.14882284900000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.085451261000000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.144400527</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.14155816700000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.14364901800000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.16980553100000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.15952327000000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.087087096999999947</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.114074747</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.083433352000000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.109351719</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.087319604000000009</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.16535071099999998</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.085455526000000004</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.085924925999999999</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.088723519000000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.11805582100000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.086636225999999983</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.075564457000000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.074940988</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.093248515000000004</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.14556818800000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.12369044300000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.14557024000000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.1763824719999999</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.14606613100000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.14864195300000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.16122792900000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.18750939500000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.159254863</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.12342580800000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.069498242000000002</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.068196053000000006</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.08690642400000001</data> + </item> + <item> + <type>int</type> + <size>256</size> + <data>0.083593906000000009</data> + </item> + </entries> +</results> diff --git a/src/boost/libs/serialization/performance/xml/int256_test.cpp b/src/boost/libs/serialization/performance/xml/int256_test.cpp new file mode 100644 index 00000000..91bd8e5c --- /dev/null +++ b/src/boost/libs/serialization/performance/xml/int256_test.cpp @@ -0,0 +1,20 @@ +/* /libs/serialization/xml_performance/int25_test.cpp ************************** + +(C) Copyright 2010 Bryce Lelbach + +Use, modification and distribution is subject to the Boost Software License, +Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +http://www.boost.org/LICENSE_1_0.txt) + +*******************************************************************************/ + +#define BSL_TYPE int +#define BSL_DEPTH 4 +#define BSL_ROUNDS 256 +#define BSL_NODE_MAX 4 +#define BSL_SAVE_TMPFILE 0 + +#include "harness.hpp" + +BSL_MAIN + diff --git a/src/boost/libs/serialization/performance/xml/int4_results.xml b/src/boost/libs/serialization/performance/xml/int4_results.xml new file mode 100644 index 00000000..0c403eb1 --- /dev/null +++ b/src/boost/libs/serialization/performance/xml/int4_results.xml @@ -0,0 +1,1291 @@ +<?xml version="1.0" encoding="UTF-8" standalone="yes" ?> +<!DOCTYPE boost_serialization> +<boost_serialization signature="serialization::archive" version="8"> +<results class_id="0" tracking_level="0" version="0"> + <compiler>GNU C++ version 4.5.1 20100617 (prerelease)</compiler> + <platform>linux</platform> + <entries class_id="1" tracking_level="0" version="0"> + <count>256</count> + <item_version>0</item_version> + <item class_id="2" tracking_level="0" version="0"> + <type>int</type> + <size>4</size> + <data>0.0064683200000000005</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0013484810000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012968400000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012938400000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.001321881</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012813600000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012798400000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00128432</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0013019210000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012802800000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00128484</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.001293043</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00128148</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012812800000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012898830000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012836800000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00128812</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.001305481</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00128188</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00129484</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0013052410000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012850400000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012983600000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012958010000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012928400000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012897200000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0013186410000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00128724</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012884400000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.001303963</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012984000000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0013423600000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00130412</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0013056810000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00128388</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012844</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012939210000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012815200000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012848800000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012886810000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012767200000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012861600000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012976020000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00127812</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00128808</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012958430000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012735600000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00129024</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012937630000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.001314801</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00128812</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012858400000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.001299681</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00128736</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012926400000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0013075610000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012856</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012841200000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0013007210000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012770400000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012774800000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012995630000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012760800000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0013167200000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.001299803</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00130152</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012791600000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00128444</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012910810000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012824800000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012862000000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012863600000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012840400000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012963220000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012926400000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00128604</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.001302683</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012925600000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012863200000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012868000000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.001301803</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012945600000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012883200000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0013074010000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00128652</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00128524</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0013003210000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.001289</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012887600000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012898010000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012779200000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.001284</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0013036830000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012790400000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00128232</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012894430000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0013535600000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012924400000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.001294201</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012804800000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00128228</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.001305081</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012888400000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012826000000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0013026020000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012876400000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012842400000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.001301321</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012849600000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012959600000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012933600000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012845600000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012874800000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012894</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.001298881</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012834000000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00128652</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0013008010000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00128472</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00128644</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012989620000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012816000000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012825200000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012950820000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00128012</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012857600000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.001298883</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00127972</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0013221600000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.001299283</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012888000000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012896400000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.001294601</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012852</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012851200000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.001312281</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012859600000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00139204</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.001303081</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012967200000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012925200000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012986430000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012917200000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012922000000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.001318963</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00128648</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.001284</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.001299641</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0014884800000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012899600000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012945610000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00128808</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00137524</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00129112</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012960020000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00127808</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012879200000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012991210000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00128476</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012820400000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.001311083</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00136856</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0013016800000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012952410000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012880000000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00128732</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012946000000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0013174810000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012829200000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012948</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.001307601</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00128432</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012834000000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012954820000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00128104</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012853200000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0013023630000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00127676</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012791600000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00128604</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00127564</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012862800000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012893610000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012794400000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012824800000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.001308121</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012832000000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012821200000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012924810000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012824800000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00127892</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.001298443</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012879600000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012920800000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0028338400000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0013351200000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0013108810000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012887600000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012856</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012970010000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012761200000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00127644</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012980820000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00127684</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012760800000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.001297201</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00127648</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012804800000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012903230000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012802800000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012727600000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012685050000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012786400000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012832400000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012928410000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012786800000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012866400000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012979200000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0013046820000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012878000000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012865600000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012973220000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012819600000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012832000000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0013041630000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012849200000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0013826000000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0013183230000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012816800000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012865600000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012882010000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012740000000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00127808</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.001292762</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012758000000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00127684</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012998010000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012753200000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.001276</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012916830000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012774800000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012794800000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012958830000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012859200000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012798</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.001303401</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00128304</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012883200000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.001291761</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012875200000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012957600000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.00129184</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0013144820000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012892800000000001</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012874400000000002</data> + </item> + <item> + <type>int</type> + <size>4</size> + <data>0.0012954830000000001</data> + </item> + </entries> +</results> diff --git a/src/boost/libs/serialization/performance/xml/int4_test.cpp b/src/boost/libs/serialization/performance/xml/int4_test.cpp new file mode 100644 index 00000000..26db6a1f --- /dev/null +++ b/src/boost/libs/serialization/performance/xml/int4_test.cpp @@ -0,0 +1,20 @@ +/* /libs/serialization/xml_performance/int5_test.cpp *************************** + +(C) Copyright 2010 Bryce Lelbach + +Use, modification and distribution is subject to the Boost Software License, +Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +http://www.boost.org/LICENSE_1_0.txt) + +*******************************************************************************/ + +#define BSL_TYPE int +#define BSL_DEPTH 1 +#define BSL_ROUNDS 256 +#define BSL_NODE_MAX 4 +#define BSL_SAVE_TMPFILE 0 + +#include "harness.hpp" + +BSL_MAIN + diff --git a/src/boost/libs/serialization/performance/xml/int64_results.xml b/src/boost/libs/serialization/performance/xml/int64_results.xml new file mode 100644 index 00000000..0234be96 --- /dev/null +++ b/src/boost/libs/serialization/performance/xml/int64_results.xml @@ -0,0 +1,1291 @@ +<?xml version="1.0" encoding="UTF-8" standalone="yes" ?> +<!DOCTYPE boost_serialization> +<boost_serialization signature="serialization::archive" version="8"> +<results class_id="0" tracking_level="0" version="0"> + <compiler>GNU C++ version 4.5.1 20100617 (prerelease)</compiler> + <platform>linux</platform> + <entries class_id="1" tracking_level="0" version="0"> + <count>256</count> + <item_version>0</item_version> + <item class_id="2" tracking_level="0" version="0"> + <type>int</type> + <size>64</size> + <data>0.019669446</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014487284000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014522886</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014541604000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014511724</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014433683000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014422160000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014430572000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014482052</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014466769000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014473404</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014467164000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014443046000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014502884000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014437164000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014470963000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014436202</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014684172000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014476372000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014445972000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014496126000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014419045</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014431766</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014509245</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014461203000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014438964</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014516004000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014467052000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014451089</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014470532000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014495084</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014541806000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014538686</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014557006000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014515684000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014478643000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014463043</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014503089</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014455809000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014486252000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014485492000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014489486000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014524406</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014491006000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014503724000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014480844000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014498644000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014424628</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014758172000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014486449</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014480489000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014488966000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014479684000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014487846</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014490003000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014495404000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014468323000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014482585000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014458649000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014433292</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014510932000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014445526</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014448486000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014487125000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014460044000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014419084</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014461804000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014440065</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014518092000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014421129000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014449812000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014491406</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014498206000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014493726</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014491084000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014521844000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014434484000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.01446416</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014464689000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014509292000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014446532000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014462526000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014507046000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014492486000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014478405000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014495164000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014410804000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014448363000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014446089</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014426529</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014439369000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014481006000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014549005</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014524126</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014579886</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014504884000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014479804000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014504883000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014493212</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.01452561199999991</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014501612000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014468292000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014477526000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014580486</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014502485000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014492244000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014523443</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014456803000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014578564</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014513652</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014602012000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014517612000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014438726000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014636246</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014512446000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014496724000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014508804</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014463284000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014476564000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014486652000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014519532000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014501529000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014499489000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014508846000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014486965000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014604445000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014466683000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014418044000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014486163000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014435129000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014433848999999888</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014466412000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014421729000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014503366</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014473445000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014462526000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014440163000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014511683000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014473923000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014486921000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014494692000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014464452000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014510572000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014450526000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014446524000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014475006</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014495605000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014441004</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014513924000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014508523000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014639452000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014492212000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014475649</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014522406000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014492246</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014547646000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014526446</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014550083</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014535804000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014513963000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014525052</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014477651999999952</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014536052000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014505209000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014549046000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014494046000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014543766000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014517763000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014560324000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014490044000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.01452084</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014468092</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014456372</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014464052000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014488444000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014533046000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014455205</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014468363000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014420884</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014514723</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014476803000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014691652000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014528652000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014488212</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014486725000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014492484000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014512206000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014477606000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014445083000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014434764000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014466163000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014462852000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014470572000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014492972000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014462692000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014505326000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014498126</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014515127000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014505484000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014550483000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014492964000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014474105000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014491652000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014511252000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014481772</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014490206</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014557166000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014467925000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014520123000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014490163</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014529804</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014479643</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014665332000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014451529000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014474492</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014458326000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014478766000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014512045000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014480244000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014506004000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014465164000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014486164000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014495092000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014493612000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014517529000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014456050000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014505726</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014472166000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014522446000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014501124000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014496084000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014433204000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.015052948000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014451772000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014503892000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014487729000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014457845</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014468924000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014471005</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014513285000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014458324000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014509163</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014488203000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014733972000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014396972000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014481252000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014464165000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014463646</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014520247000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014405925000000002</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014428203000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014457364</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014505124000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014459212000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014439049000000001</data> + </item> + <item> + <type>int</type> + <size>64</size> + <data>0.014547252</data> + </item> + </entries> +</results> diff --git a/src/boost/libs/serialization/performance/xml/int64_test.cpp b/src/boost/libs/serialization/performance/xml/int64_test.cpp new file mode 100644 index 00000000..f7a51e33 --- /dev/null +++ b/src/boost/libs/serialization/performance/xml/int64_test.cpp @@ -0,0 +1,20 @@ +/* /libs/serialization/xml_performance/int25_test.cpp ************************** + +(C) Copyright 2010 Bryce Lelbach + +Use, modification and distribution is subject to the Boost Software License, +Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +http://www.boost.org/LICENSE_1_0.txt) + +*******************************************************************************/ + +#define BSL_TYPE int +#define BSL_DEPTH 3 +#define BSL_ROUNDS 256 +#define BSL_NODE_MAX 4 +#define BSL_SAVE_TMPFILE 0 + +#include "harness.hpp" + +BSL_MAIN + diff --git a/src/boost/libs/serialization/performance/xml/macro.hpp b/src/boost/libs/serialization/performance/xml/macro.hpp new file mode 100644 index 00000000..6f8cbf96 --- /dev/null +++ b/src/boost/libs/serialization/performance/xml/macro.hpp @@ -0,0 +1,229 @@ +/* /libs/serialization/xml_performance/macro.hpp ******************************* + +(C) Copyright 2010 Bryce Lelbach + +Use, modification and distribution is subject to the Boost Software License, +Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +http://www.boost.org/LICENSE_1_0.txt) + +*******************************************************************************/ + +#if !defined(BOOST_SERIALIZATION_XML_PERFORMANCE_MACRO_HPP) +#define BOOST_SERIALIZATION_XML_PERFORMANCE_MACRO_HPP + +#if defined(_MSC_VER) + #pragma once +#endif + +#include <boost/preprocessor.hpp> + +#if !defined(BSL_NODE_MAX) + #define BSL_NODE_MAX 4 +#endif + +#if !defined(BSL_DEPTH) + #define BSL_DEPTH 2 +#endif + +#if !defined(BSL_ROUNDS) + #define BSL_ROUNDS 256 +#endif + +#if !defined(BSL_TYPE) + #define BSL_TYPE int +#endif + +#if !defined(BSL_SAVE_TMPFILE) + #define BSL_SAVE_TMPFILE 0 +#endif + +#if !defined(BSL_RESULTS_FILE) + #define BSL_RESULTS_FILE \ + BOOST_PP_STRINGIZE(BSL_TYPE) \ + BOOST_PP_STRINGIZE(BSL_EXP(BSL_NODE_MAX, BSL_DEPTH)) \ + "_results.xml" \ + /**/ +#endif + +// utility print macro + +#define BSL_PRINT(Z, N, T) T + +// preprocessor power function, BSL_EXP + +#define BSL_EXP_PRED(B, D) BOOST_PP_TUPLE_ELEM(3, 0, D) + +#define BSL_EXP_OP(B, D) \ + ( \ + BOOST_PP_DEC(BOOST_PP_TUPLE_ELEM(3, 0, D)), \ + BOOST_PP_TUPLE_ELEM(3, 1, D), \ + BOOST_PP_MUL_D( \ + B, \ + BOOST_PP_TUPLE_ELEM(3, 2, D), \ + BOOST_PP_TUPLE_ELEM(3, 1, D) \ + ) \ + ) \ + /**/ + +#define BSL_EXP(X, N) \ + BOOST_PP_TUPLE_ELEM( \ + 3, 2, BOOST_PP_WHILE(BSL_EXP_PRED, BSL_EXP_OP, (N, X, 1)) \ + ) \ + /**/ + +// boost::archive::xml::node macros + +#define BSL_NODE_DECL_MEMBER(Z, N, _) T ## N element ## N ; +#define BSL_NODE_DECL_NONE(Z, N, _) unused_type element ## N ; +#define BSL_NODE_xDECL_CTOR() node (void) { } + +#define BSL_NODE_DECL_CTOR(P) \ + BOOST_PP_IF(P, \ + BSL_NODE_xDECL_CTOR, \ + BOOST_PP_EMPTY \ + )() \ + /**/ + +#define BSL_NODE_SERIALIZE(Z, N, _) \ + & BOOST_SERIALIZATION_NVP(BOOST_PP_CAT(element, N)) \ + /**/ + +#define BSL_NODE_INIT_LIST(Z, N, _) \ + BOOST_PP_COMMA_IF(N) BOOST_PP_CAT(element, N) \ + BOOST_PP_LPAREN() BOOST_PP_CAT(p, N) BOOST_PP_RPAREN() \ + /**/ + +#define BSL_NODE_DECL(Z, N, _) \ + template<BOOST_PP_ENUM_PARAMS_Z(Z, N, typename T)> \ + struct node< \ + BOOST_PP_ENUM_PARAMS_Z(Z, N, T) \ + BOOST_PP_COMMA_IF(N) \ + BOOST_PP_ENUM_ ## Z(BOOST_PP_SUB(BSL_NODE_MAX, N), BSL_PRINT, unused_type) \ + > { \ + BOOST_PP_REPEAT_ ## Z(N, BSL_NODE_DECL_MEMBER, _) \ + \ + BOOST_PP_REPEAT_FROM_TO_ ## Z(N, BSL_NODE_MAX, BSL_NODE_DECL_NONE, _) \ + \ + template<class ARC> \ + void serialize (ARC& ar, const unsigned int) { \ + ar BOOST_PP_REPEAT_ ## Z(N, BSL_NODE_SERIALIZE, _); \ + } \ + \ + BSL_NODE_DECL_CTOR(N) \ + \ + node (BOOST_PP_ENUM_BINARY_PARAMS_Z(Z, N, T, p)): \ + BOOST_PP_REPEAT_ ## Z(N, BSL_NODE_INIT_LIST, _) { } \ + }; \ + /**/ + +// instantiation macros + +#define BSL_INST_BASE(Z, N, L) \ + T0 T0 ## _ ## N(BOOST_PP_ENUM_ ## Z( \ + BSL_NODE_MAX, BSL_PRINT, \ + boost::archive::xml::random<BSL_TYPE> BOOST_PP_LPAREN() BOOST_PP_RPAREN() \ + )); \ + /**/ + +#define BSL_INST_yNODES(Z, N, L) \ + BOOST_PP_COMMA_IF(N) \ + BOOST_PP_CAT(T, \ + BOOST_PP_CAT(BOOST_PP_LIST_AT(L, 1), \ + BOOST_PP_CAT(_, \ + BOOST_PP_ADD(N, \ + BOOST_PP_LIST_AT(L, 0) \ + ) \ + ) \ + ) \ + ) \ + /**/ + +#define BSL_INST_xNODES(Z, N, L) \ + T ## L T ## L ## _ ## N( \ + BOOST_PP_REPEAT_ ## Z( \ + BSL_NODE_MAX, BSL_INST_yNODES, \ + (BOOST_PP_MUL(N, BSL_NODE_MAX), (BOOST_PP_SUB(L, 1), BOOST_PP_NIL)) \ + ) \ + ); \ + /**/ + +#define BSL_INST_NODES(Z, N, L) \ + BOOST_PP_REPEAT_ ## Z( \ + BSL_EXP(BSL_NODE_MAX, BOOST_PP_SUB(BSL_DEPTH, N)), \ + BSL_INST_xNODES, N \ + ) \ + /**/ + +#define BSL_TYPEDEF_NODES(Z, N, L) \ + typedef boost::archive::xml::node< \ + BOOST_PP_ENUM_ ## Z( \ + BSL_NODE_MAX, BSL_PRINT, BOOST_PP_CAT(T, BOOST_PP_SUB(N, 1)) \ + ) \ + > T ## N; \ + /**/ + +// main macro + +#define BSL_MAIN \ + int main (void) { \ + using namespace boost::archive; \ + using namespace boost::archive::xml; \ + \ + typedef node<BOOST_PP_ENUM(BSL_NODE_MAX, BSL_PRINT, BSL_TYPE)> T0; \ + \ + BOOST_PP_REPEAT_FROM_TO(1, BSL_DEPTH, BSL_TYPEDEF_NODES, _) \ + \ + typedef node<BOOST_PP_ENUM( \ + BSL_NODE_MAX, BSL_PRINT, \ + BOOST_PP_CAT(T, BOOST_PP_SUB(BSL_DEPTH, 1)) \ + )> HEAD; \ + \ + result_set results; \ + std::size_t rounds = BSL_ROUNDS; \ + \ + while (rounds --> 0) { \ + BOOST_PP_REPEAT(BSL_EXP(BSL_NODE_MAX, BSL_DEPTH), BSL_INST_BASE, _) \ + \ + BOOST_PP_REPEAT_FROM_TO(1, BSL_DEPTH, BSL_INST_NODES, _) \ + \ + HEAD h(BOOST_PP_ENUM_PARAMS( \ + BSL_NODE_MAX, \ + BOOST_PP_CAT(T, BOOST_PP_CAT(BOOST_PP_SUB(BSL_DEPTH, 1), _)) \ + )); \ + \ + std::string fn = save_archive(h); \ + \ + std::pair<double, HEAD> r = restore_archive<HEAD>(fn); \ + \ + std::cout << "round " \ + << ((BSL_ROUNDS - 1) - rounds) \ + << " -> " << fn << "\n"; \ + \ + BOOST_PP_IF(BSL_SAVE_TMPFILE, \ + BOOST_PP_EMPTY(), \ + std::remove(fn.c_str()); \ + ) \ + \ + results.entries.push_back(entry( \ + BOOST_PP_STRINGIZE(BSL_TYPE), \ + BSL_EXP(BSL_NODE_MAX, BSL_DEPTH), r.first \ + )); \ + } \ + \ + std::fstream fs(BSL_RESULTS_FILE, std::fstream::in); \ + \ + if (fs.good()) { \ + xml_iarchive ia(fs); \ + ia >> BOOST_SERIALIZATION_NVP(results); \ + fs.close(); \ + } \ + \ + fs.open(BSL_RESULTS_FILE, std::fstream::out | std::fstream::trunc); \ + xml_oarchive oa(fs); \ + oa << BOOST_SERIALIZATION_NVP(results); \ + \ + fs.close(); \ + } \ + /**/ + +#endif // BOOST_SERIALIZATION_XML_PERFORMANCE_MACRO_HPP diff --git a/src/boost/libs/serialization/performance/xml/node.hpp b/src/boost/libs/serialization/performance/xml/node.hpp new file mode 100644 index 00000000..99f36759 --- /dev/null +++ b/src/boost/libs/serialization/performance/xml/node.hpp @@ -0,0 +1,63 @@ +/* /libs/serialization/xml_performance/node.hpp ******************************** + +(C) Copyright 2010 Bryce Lelbach + +Use, modification and distribution is subject to the Boost Software License, +Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +http://www.boost.org/LICENSE_1_0.txt) + +*******************************************************************************/ + +#if !defined(BOOST_SERIALIZATION_XML_PERFORMANCE_NODE_HPP) +#define BOOST_SERIALIZATION_XML_PERFORMANCE_NODE_HPP + +#if defined(_MSC_VER) + #pragma once +#endif + +#include <boost/serialization/nvp.hpp> +#include <boost/serialization/utility.hpp> +#include <boost/serialization/list.hpp> +#include <boost/serialization/version.hpp> + +#include "macro.hpp" + +namespace boost { +namespace archive { +namespace xml { + +struct unused_type { }; + +template< + typename T, + BOOST_PP_ENUM_PARAMS_WITH_A_DEFAULT( + BOOST_PP_SUB(BSL_NODE_MAX, 1), typename T, unused_type + ) +> struct node; + +BOOST_PP_REPEAT_FROM_TO(1, BSL_NODE_MAX, BSL_NODE_DECL, _) + +template<BOOST_PP_ENUM_PARAMS(BSL_NODE_MAX, typename T)> +struct node { + BOOST_PP_REPEAT(BSL_NODE_MAX, BSL_NODE_DECL_MEMBER, _) + + template<class ARC> + void serialize (ARC& ar, const unsigned int) { + ar + BOOST_PP_REPEAT(BSL_NODE_MAX, BSL_NODE_SERIALIZE, _) + ; + } + + BSL_NODE_xDECL_CTOR() + + node (BOOST_PP_ENUM_BINARY_PARAMS(BSL_NODE_MAX, T, p)): + BOOST_PP_REPEAT(BSL_NODE_MAX, BSL_NODE_INIT_LIST, _) + { } +}; + +} // xml +} // archive +} // boost + +#endif // BOOST_SERIALIZATION_XML_PERFORMANCE_NODE_HPP + diff --git a/src/boost/libs/serialization/performance/xml/string16_results.xml b/src/boost/libs/serialization/performance/xml/string16_results.xml new file mode 100644 index 00000000..4113087b --- /dev/null +++ b/src/boost/libs/serialization/performance/xml/string16_results.xml @@ -0,0 +1,1291 @@ +<?xml version="1.0" encoding="UTF-8" standalone="yes" ?> +<!DOCTYPE boost_serialization> +<boost_serialization signature="serialization::archive" version="8"> +<results class_id="0" tracking_level="0" version="0"> + <compiler>GNU C++ version 4.5.1 20100617 (prerelease)</compiler> + <platform>linux</platform> + <entries class_id="1" tracking_level="0" version="0"> + <count>256</count> + <item_version>0</item_version> + <item class_id="2" tracking_level="0" version="0"> + <type>string</type> + <size>16</size> + <data>0.012478289</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072560000000000003</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072030420000000006</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071682020000000003</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071778060000000001</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072362460000000009</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071869220000000001</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071878830000000008</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071994860000000006</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.007244566</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071920810000000003</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072397640000000001</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071930430000000005</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071888830000000001</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071856820000000005</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071798830000000006</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071797230000000007</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071992860000000001</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072556420000000005</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072098020000000004</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.007207321</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072045260000000002</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071889830000000004</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071904010000000008</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071754830000000007</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072048060000000002</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072293660000000001</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072043620000000006</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072351230000000004</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072088830000000001</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071613630000000005</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071968020000000004</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072091630000000002</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071625610000000004</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071758860000000002</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072168020000000005</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072034020000000002</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071784030000000007</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072256860000000003</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072109220000000007</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071665210000000003</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072158430000000004</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072299660000000009</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072064680000000006</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071831220000000001</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071800030000000008</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072292860000000006</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071624430000000001</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071836820000000003</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072084030000000004</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071665620000000005</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072477660000000001</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072076020000000005</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072072030000000006</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072176030000000004</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071833660000000001</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071831220000000001</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071601210000000002</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072026430000000008</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071991260000000001</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072078410000000004</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072082020000000004</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071928830000000006</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071964460000000004</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071826460000000009</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071702020000000005</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071683230000000007</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071388030000000009</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072348860000000003</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071883620000000002</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071758410000000005</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071781630000000004</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071760060000000004</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072201620000000005</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071673630000000004</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071732830000000008</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071706460000000001</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072266420000000001</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072288420000000001</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072125630000000008</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072115630000000007</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071812000000000004</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.007202122</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.007167362</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072384060000000002</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072055260000000003</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072029620000000003</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071922830000000007</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071877260000000002</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072153660000000008</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072294010000000008</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071974830000000002</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071855230000000001</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071989230000000003</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072465620000000007</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071857230000000006</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072022430000000005</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072071660000000001</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072090020000000008</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072011620000000005</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072017610000000001</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071964060000000007</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072420000000000002</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071690410000000001</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071992430000000001</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071818460000000004</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071558030000000005</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071756420000000003</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072259230000000004</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071872860000000002</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072312860000000008</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072287620000000006</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071818030000000005</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071858810000000007</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071967260000000005</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071914020000000004</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071645210000000001</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071816830000000003</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071695260000000007</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072521220000000006</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072282020000000004</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072272830000000001</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072088460000000005</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071882650000000001</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.007179922</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072016430000000006</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071915230000000009</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072753260000000004</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072302020000000007</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.007209923</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.007189122</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072191260000000002</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072180020000000003</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071952810000000004</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071876430000000005</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071936060000000008</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072690820000000005</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072184420000000003</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072203630000000005</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071952060000000009</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071918810000000007</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071836420000000005</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072154830000000008</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071770830000000008</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072342460000000006</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072119220000000008</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.007218683</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072250430000000004</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072196860000000003</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072206420000000002</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072086820000000001</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072429630000000007</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072798060000000006</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072191220000000006</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072123220000000002</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071857230000000006</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071828060000000008</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071980010000000007</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072397220000000005</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072392030000000005</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.007219446</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072401210000000004</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072177220000000002</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072424830000000001</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071834030000000005</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072027260000000004</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071956820000000001</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072182430000000001</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071804460000000001</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072502860000000008</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072154820000000005</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072068410000000003</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071990430000000005</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072062060000000006</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072053220000000001</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071906030000000003</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071940830000000004</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072020060000000004</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072318010000000004</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071934820000000002</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072077230000000001</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071936460000000006</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071854800000000002</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071955220000000002</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071776030000000003</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071916830000000008</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072421260000000006</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.007211322</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071732020000000001</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071748060000000006</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071980060000000007</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072117220000000003</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072090420000000006</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072236430000000001</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072546460000000009</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071919610000000002</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071797630000000005</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.007174723</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071845260000000001</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071910020000000002</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072310020000000003</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072686430000000008</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071835230000000007</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072432400000000006</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.007220962</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071698030000000006</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071864460000000008</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071785260000000002</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072036020000000008</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071802010000000006</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071924460000000008</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072578860000000007</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072124820000000001</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072392830000000009</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072244830000000003</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071948460000000004</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071743210000000009</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.007205922</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071905630000000005</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071846830000000007</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072338420000000007</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072037220000000001</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071850030000000006</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071687630000000007</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071699850000000002</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071892820000000008</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071742420000000008</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071893660000000009</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072221260000000006</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071861620000000003</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071887230000000002</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071893630000000007</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071844860000000003</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071784010000000001</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072017230000000002</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072007630000000006</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072040859999998874</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072226420000000005</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072083620000000003</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072103630000000009</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071846830000000007</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072017620000000004</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072684820000000006</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071865230000000002</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071598460000000001</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072246680000000001</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071868820000000003</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071647230000000004</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072765660000000008</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071751260000000004</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071459620000000005</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072247630000000004</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071712020000000007</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072490860000000001</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0071670820000000008</data> + </item> + <item> + <type>string</type> + <size>16</size> + <data>0.0072127220000000004</data> + </item> + </entries> +</results> diff --git a/src/boost/libs/serialization/performance/xml/string16_test.cpp b/src/boost/libs/serialization/performance/xml/string16_test.cpp new file mode 100644 index 00000000..ad42eada --- /dev/null +++ b/src/boost/libs/serialization/performance/xml/string16_test.cpp @@ -0,0 +1,24 @@ +/* /libs/serialization/xml_performance/string25_test.cpp *********************** + +(C) Copyright 2010 Bryce Lelbach + +Use, modification and distribution is subject to the Boost Software License, +Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +http://www.boost.org/LICENSE_1_0.txt) + +*******************************************************************************/ + +#include <string> + +typedef std::string string; + +#define BSL_TYPE string +#define BSL_DEPTH 2 +#define BSL_ROUNDS 256 +#define BSL_NODE_MAX 4 +#define BSL_SAVE_TMPFILE 0 + +#include "harness.hpp" + +BSL_MAIN + diff --git a/src/boost/libs/serialization/performance/xml/string256_results.xml b/src/boost/libs/serialization/performance/xml/string256_results.xml new file mode 100644 index 00000000..09e7cda0 --- /dev/null +++ b/src/boost/libs/serialization/performance/xml/string256_results.xml @@ -0,0 +1,1291 @@ +<?xml version="1.0" encoding="UTF-8" standalone="yes" ?> +<!DOCTYPE boost_serialization> +<boost_serialization signature="serialization::archive" version="8"> +<results class_id="0" tracking_level="0" version="0"> + <compiler>GNU C++ version 4.5.1 20100617 (prerelease)</compiler> + <platform>linux</platform> + <entries class_id="1" tracking_level="0" version="0"> + <count>256</count> + <item_version>0</item_version> + <item class_id="2" tracking_level="0" version="0"> + <type>string</type> + <size>256</size> + <data>0.24082843600000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.15478449400000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.14540435600000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.14332035000000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.14574748900000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.162143815</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.143199773</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.14591024800000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.148218763</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.26581049599999995</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.15119754200000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.25551917900000004</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.30426230999999992</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.23429972399999999</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.152736329</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.16095108700000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.257406205</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.21526160400000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.310253734</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.30385512799999992</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.277919476</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.15155350300000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.2247563669999999</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.311096769</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.18083700100000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.25365826600000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.146422422</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.31615557699999997</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.17431823499999999</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.30721216100000004</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.274691929</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.25493901099999999</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.24813491900000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.21902227400000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.182308211</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.14080317399999998</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.27130100700000004</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.141822905</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.234210945</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.18912357100000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.23694535000000003</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.30294369100000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.23246992800000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.15832027100000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.26319235099999994</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.147053033</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.30371506200000004</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.306945248</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.34078868499999992</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.16450026000000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.353907258</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.29755154299999997</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.31086977300000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.166196543</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.29479566800000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.29576432800000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.18159834400000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.19346430100000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.15868047100000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.18001983300000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.30650560900000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.16728085300000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.28264082199999996</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.23873842499999998</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.142975195</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.306175533</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.28568148900000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.27912233200000003</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.24095708900000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.29895117200000004</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.31077380700000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.22219352000000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.17159283699999994</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.18810837300000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.31016322400000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.24117843300000003</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.25069571300000004</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.35484542899999993</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.25646144200000004</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.23715143800000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.17434978100000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.22196388700000003</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.31783167000000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.44040980399999996</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.18985125600000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.16910165699999991</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.22861478000000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.32245771200000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.18971205300000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.34642208599999991</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.16614582600000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.29925598899999994</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.29850647600000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.172233461</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.21215700399999993</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.21100386000000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.24862557099999993</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.16703737700000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.25782752200000003</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.26164129199999997</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.57651874200000008</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.36986256299999998</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.21878367700000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.17820567400000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.24184889000000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.24552513400000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.33087374899999999</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.344138096</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.25427008900000003</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.33677569699999998</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.33239564400000005</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.29225137200000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.23854207300000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.21931018499999999</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.33166821100000005</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.33713559600000004</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.35802521499999995</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.21386164400000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.35509271800000003</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.16676263400000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.23069279500000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.33617436300000003</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.336949834</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.34125201800000005</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.33968717300000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.34125770800000005</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.32101234700000003</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.33470459899999994</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.18704252400000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.28705466900000004</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.29912810300000003</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.17272062800000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.20886833600000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.33794845900000003</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.264968284</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.26913011600000003</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.25145834900000003</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.33495682699999996</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.26798035000000003</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.24842696600000003</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.33503277800000003</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.30332787699999997</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.28991897599999999</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.33133644100000004</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.26798883300000004</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.291365229</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.34162038900000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.170376363</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.170955098</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.17217529200000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.2625844249999999</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.25749087800000003</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.214833564</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.20960021100000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.20222120200000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.28324146</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.303095801</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.31430344799999999</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.23109986400000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.20973660100000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.26268180499999999</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.34926366799999997</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.22327798399999998</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.16531669100000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.17791732599999999</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.16743454199999996</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.190363907</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.16638140000000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.31061568700000003</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.29818055100000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.16645938000000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.16849109600000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.19088629400000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.233309764</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.26293923899999999</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.20451668599999995</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.18545595400000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.33442231900000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.307385672</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.23357416</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.287179342</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.20827706400000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.42202693800000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.34912425000000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.241049968</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.21442900300000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.34573371899999999</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.31089394199999998</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.26286895299999991</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.28370315699999993</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.17465668500000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.348761398</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.166838869</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.26464613599999998</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.29856266600000003</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.24585868199999994</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.27416464800000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.33280198300000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.23629951400000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.31782385300000005</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.17180628100000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.31635188200000003</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.291131843</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.19067002899999996</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.23594924</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.32661452500000004</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.228596355</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.25246959299999999</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.34272192000000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.24635339900000003</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.23385871399999991</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.168213903</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.27104451799999996</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.28353989400000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.27119438400000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.31294787200000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.263878267</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.26840745700000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.19721746600000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.21171784800000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.31691192800000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.16284852300000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.206485163</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.17293324500000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.30097051599999991</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.18753556099999991</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.352919066</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.23880742000000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.21931351400000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.30510558200000004</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.306646945</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.19290866000000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.31661062500000003</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.15527985900000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.21309966899999999</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.25295672000000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.31927861000000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.28013629200000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.23187213000000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.241622844</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.28193659500000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.25082649800000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.21928747300000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.213718137</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.31063365000000004</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.16080174</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.30793034600000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.18621517200000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.31502906899999999</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.20341706500000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.16701237700000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.18218058300000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.31295746400000002</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.22039852299999996</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.16650589500000001</data> + </item> + <item> + <type>string</type> + <size>256</size> + <data>0.30901178699999998</data> + </item> + </entries> +</results> diff --git a/src/boost/libs/serialization/performance/xml/string256_test.cpp b/src/boost/libs/serialization/performance/xml/string256_test.cpp new file mode 100644 index 00000000..b68c5123 --- /dev/null +++ b/src/boost/libs/serialization/performance/xml/string256_test.cpp @@ -0,0 +1,24 @@ +/* /libs/serialization/xml_performance/string25_test.cpp *********************** + +(C) Copyright 2010 Bryce Lelbach + +Use, modification and distribution is subject to the Boost Software License, +Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +http://www.boost.org/LICENSE_1_0.txt) + +*******************************************************************************/ + +#include <string> + +typedef std::string string; + +#define BSL_TYPE string +#define BSL_DEPTH 4 +#define BSL_ROUNDS 256 +#define BSL_NODE_MAX 4 +#define BSL_SAVE_TMPFILE 0 + +#include "harness.hpp" + +BSL_MAIN + diff --git a/src/boost/libs/serialization/performance/xml/string4_results.xml b/src/boost/libs/serialization/performance/xml/string4_results.xml new file mode 100644 index 00000000..6381eb69 --- /dev/null +++ b/src/boost/libs/serialization/performance/xml/string4_results.xml @@ -0,0 +1,1291 @@ +<?xml version="1.0" encoding="UTF-8" standalone="yes" ?> +<!DOCTYPE boost_serialization> +<boost_serialization signature="serialization::archive" version="8"> +<results class_id="0" tracking_level="0" version="0"> + <compiler>GNU C++ version 4.5.1 20100617 (prerelease)</compiler> + <platform>linux</platform> + <entries class_id="1" tracking_level="0" version="0"> + <count>256</count> + <item_version>0</item_version> + <item class_id="2" tracking_level="0" version="0"> + <type>string</type> + <size>4</size> + <data>0.0074473220000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0021171600000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0021249610000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020889610000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020989610000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0021022810000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020897610000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.00207932</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020796</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.00206676</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0021010830000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020941230000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020960029999999999</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0022728430000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0021422430000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0021111599999999999</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020897210000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020777199999999999</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.00207756</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020766400000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020919610000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020888820000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020911620000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.002101922</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.00207456</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020878400000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020859200000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.002087963</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0021150030000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020946430000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.002101323</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020741600000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.00207048</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020697200000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020688</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020761210000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0021957610000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.002088922</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020608800000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.00207632</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020790000000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020759200000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.002086563</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020913630000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0021061630000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0021424030000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020861200000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020792000000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020831199999999999</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020748800000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020908810000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020839210000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020882019999999999</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020667200000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020760000000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020742</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020731200000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.002098721</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.002094963</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020910030000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0021128430000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020812000000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020832800000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020760800000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020872810000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.002092801</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020863209999999999</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.002081641</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020940020000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020796400000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.00207428</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020808800000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.002087401</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.002102881</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020912830000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.002095043</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020720000000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0021351600000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020774000000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020770000000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020883210000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.002102521</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020871209999999999</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020829210000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020788</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0022383620000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0021013220000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020742400000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020818799999999999</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.00208304</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020769600000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020958030000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.002107083</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020970430000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.002090083</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020642</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.00206924</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020811600000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020840810000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020956010000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0021117220000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.002084762</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020757600000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020830800000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020730800000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020841200000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0021030430000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.002085763</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0022383630000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0021111630000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020823600000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020833200000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020757200000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020928410000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0021011610000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020833610000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020972820000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020638800000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020747600000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020711200000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020848810000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0021020430000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.002103443</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020883630000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020817600000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020656800000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020790000000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020752000000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.002078641</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020934009999999999</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020846810000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020884010000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.00208224</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020734400000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020746000000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020917209999999999</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.002091561</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.002099643</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020947230000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020736000000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0021564399999999999</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0021086</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020864400000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020888009999999999</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020872410000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0021153610000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020850809999999999</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020748800000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020727600000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.00206544</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020935610000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020951210000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020952810000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.002109203</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020785199999999999</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020814800000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.00207932</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020870800000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0021083600000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020882410000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020863209999999999</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020938810000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020698400000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.00207412</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020688</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.00208376</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020955610000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020943610000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020893610000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020961230000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020729200000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.00206996</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0021200800000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020985630000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0021015600000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.002084481</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020864810000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020774400000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020692800000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.00207136</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020879610000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.002089441</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0021005609999999999</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0021022409999999999</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020743200000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020792800000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020774000000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020765600000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020830830000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020838829999999999</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020982410000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020833610000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020726</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020782800000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020529599999999999</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0021279210000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.002089161</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020892010000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.00207544</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020828400000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020691200000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.00207704</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020880429999999999</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020918429999999999</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0021526430000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.002085323</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020922810000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020669200000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.00215372</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.00207304</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.002076601</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020949620000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.002083321</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.002073961</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020738000000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020674400000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.00207888</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020933230000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020924430000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0021093230000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020860030000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020732400000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020663999999999999</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.00206828</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020734</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020888009999999999</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020840010000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0021071610000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020698800000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.002078</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020668800000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020828000000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0021036430000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.002105923</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.002094963</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0022069630000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.00209384</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020772</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020736800000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020742</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020923210000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.002086081</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020877210000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020729200000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0021266810000000001</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020851610000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.00208464</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020736400000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020819600000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020852399999999999</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020909230000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.002100963</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020798030000000003</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.002048865</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020709600000000002</data> + </item> + <item> + <type>string</type> + <size>4</size> + <data>0.0020917600000000002</data> + </item> + </entries> +</results> diff --git a/src/boost/libs/serialization/performance/xml/string4_test.cpp b/src/boost/libs/serialization/performance/xml/string4_test.cpp new file mode 100644 index 00000000..a87c0bbc --- /dev/null +++ b/src/boost/libs/serialization/performance/xml/string4_test.cpp @@ -0,0 +1,24 @@ +/* /libs/serialization/xml_performance/string5_test.cpp ************************ + +(C) Copyright 2010 Bryce Lelbach + +Use, modification and distribution is subject to the Boost Software License, +Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +http://www.boost.org/LICENSE_1_0.txt) + +*******************************************************************************/ + +#include <string> + +typedef std::string string; + +#define BSL_TYPE string +#define BSL_DEPTH 1 +#define BSL_ROUNDS 256 +#define BSL_NODE_MAX 4 +#define BSL_SAVE_TMPFILE 0 + +#include "harness.hpp" + +BSL_MAIN + diff --git a/src/boost/libs/serialization/performance/xml/string64_results.xml b/src/boost/libs/serialization/performance/xml/string64_results.xml new file mode 100644 index 00000000..0c6dd61b --- /dev/null +++ b/src/boost/libs/serialization/performance/xml/string64_results.xml @@ -0,0 +1,1291 @@ +<?xml version="1.0" encoding="UTF-8" standalone="yes" ?> +<!DOCTYPE boost_serialization> +<boost_serialization signature="serialization::archive" version="8"> +<results class_id="0" tracking_level="0" version="0"> + <compiler>GNU C++ version 4.5.1 20100617 (prerelease)</compiler> + <platform>linux</platform> + <entries class_id="1" tracking_level="0" version="0"> + <count>256</count> + <item_version>0</item_version> + <item class_id="2" tracking_level="0" version="0"> + <type>string</type> + <size>64</size> + <data>0.032849208000000005</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027500566000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027451327000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027459310000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027409781000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027785380999999942</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027489781000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027510701000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027549732</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027456249000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027514171</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.02757565</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027492611</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027502767000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027517847000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027530807000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027565327000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027517444000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027542341000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027525541000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027602181000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027534101000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027491539000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027615651000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027528491000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027536010000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027506650000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027591449000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027568327</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027615967000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027532167000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027549087000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027636750000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.033203064000000004</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027562501000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027484821000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027475901</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027442895000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027424131000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027452170000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027489530000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027491611000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027540329000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027551367</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027500207000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027557087000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027513927000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027486718</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027924781000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027442101</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027467501000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027566061000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027441051000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027590011000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027544210000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.02752425</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027618371000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027548727000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027522687000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027526447000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027556727000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027505950000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027557421000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027538700999999888</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027576901000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027507901000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027592498</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027575250000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027515571000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027482651</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027488170000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027652449000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027509127000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027598727000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027549807000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027606287</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027548792000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027512221000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027756460999999955</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027540181</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027546621</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027576093000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027483489000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027560690000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027573130000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027519331000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027563687000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027538127000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027482087000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027507527</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027609726000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027489240000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027490021000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027504140999999982</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027508021000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027476421000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027566891000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027467090000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027596731000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027603850000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027543370000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027497287000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027564527000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027462127000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027475286000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027454365000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027497301000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027490581</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027542981000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027498461000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027499541000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027512971000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027546411000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027550209000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027480250000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027508009000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027507007</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027574567000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027455566000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027504607</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027463672000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027678861000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027500861000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027479541000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027560741000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027520495000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027470051000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027435090000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027529330000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027526049</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027518048000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027476686</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027496167000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027677887000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027653447000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027444680000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027470621000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027427941000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027514701000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027530581000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.02742785</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027486410000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027441931000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027472611000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027543169000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027448767000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027436287</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027571407000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027521287000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027472364000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027511181000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.028075300999999886</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027459541000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027472981</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027476179000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027502249000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027453571000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027541969000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027626410000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027644890000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027532927000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027655526000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027602647000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027518967000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027523947</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027511461000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027583540999999934</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027469901000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027504741000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027594818</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027498931000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.02751605</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027519130000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027566811</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.02766093</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027595167</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027505447000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027495406</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027481407000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027461713000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027512301000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027660660999999975</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027531381000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027476181000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027551693000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.02747109</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027675011000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027477691000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027453569000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027546848000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027615687000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027535927000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027526766000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027491245000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027559138</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027477061000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027517181000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027551421000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027533621000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027495289000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027478930000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027494170000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027549171000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027530529000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027580927000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027560406000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027538047000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027684046</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027510467</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027602541000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027593101000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027597261000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027524541000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027597696000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027612531000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027652890000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027569450000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027542971000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027531930000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027596847000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027515367000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027395526000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027510847000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027532389000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027653221000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027480381000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027523341000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027545901000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027552058000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027556891</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.02759725</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027615211000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027532371000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027467209000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027508167</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027547567000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027625847000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027527047000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027561192000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027590181000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027565781000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027491221000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027549341000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027529575000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027578011000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027560330000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027543449000000001</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027562091</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027551447000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027531247000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027608247000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027568047000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027576647000000003</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027502877000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027854221000000002</data> + </item> + <item> + <type>string</type> + <size>64</size> + <data>0.027568421000000003</data> + </item> + </entries> +</results> diff --git a/src/boost/libs/serialization/performance/xml/string64_test.cpp b/src/boost/libs/serialization/performance/xml/string64_test.cpp new file mode 100644 index 00000000..2934084f --- /dev/null +++ b/src/boost/libs/serialization/performance/xml/string64_test.cpp @@ -0,0 +1,24 @@ +/* /libs/serialization/xml_performance/string25_test.cpp *********************** + +(C) Copyright 2010 Bryce Lelbach + +Use, modification and distribution is subject to the Boost Software License, +Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +http://www.boost.org/LICENSE_1_0.txt) + +*******************************************************************************/ + +#include <string> + +typedef std::string string; + +#define BSL_TYPE string +#define BSL_DEPTH 3 +#define BSL_ROUNDS 256 +#define BSL_NODE_MAX 4 +#define BSL_SAVE_TMPFILE 0 + +#include "harness.hpp" + +BSL_MAIN + diff --git a/src/boost/libs/serialization/performance/xml_archive.hpp b/src/boost/libs/serialization/performance/xml_archive.hpp new file mode 100644 index 00000000..1e3bdc1a --- /dev/null +++ b/src/boost/libs/serialization/performance/xml_archive.hpp @@ -0,0 +1,16 @@ +// (C) Copyright 2002-4 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. +// xml_archive +#include <boost/archive/xml_oarchive.hpp> +typedef boost::archive::xml_oarchive test_oarchive; +typedef std::ofstream test_ostream; +#include <boost/archive/xml_iarchive.hpp> +typedef boost::archive::xml_iarchive test_iarchive; +typedef std::ifstream test_istream; +#define TEST_STREAM_FLAGS (std::ios_base::openmode)0 + + diff --git a/src/boost/libs/serialization/performance/xml_warchive.hpp b/src/boost/libs/serialization/performance/xml_warchive.hpp new file mode 100644 index 00000000..3483e225 --- /dev/null +++ b/src/boost/libs/serialization/performance/xml_warchive.hpp @@ -0,0 +1,16 @@ +// (C) Copyright 2002-4 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. +// xml_warchive +#include <boost/archive/xml_woarchive.hpp> +typedef boost::archive::xml_woarchive test_oarchive; +typedef std::wofstream test_ostream; +#include <boost/archive/xml_wiarchive.hpp> +typedef boost::archive::xml_wiarchive test_iarchive; +typedef std::wifstream test_istream; +#define TEST_STREAM_FLAGS (std::ios_base::openmode)0 + + diff --git a/src/boost/libs/serialization/src/archive_exception.cpp b/src/boost/libs/serialization/src/archive_exception.cpp new file mode 100644 index 00000000..729a4edb --- /dev/null +++ b/src/boost/libs/serialization/src/archive_exception.cpp @@ -0,0 +1,154 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// archive_exception.cpp: + +// (C) Copyright 2009 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#if (defined _MSC_VER) && (_MSC_VER == 1200) +# pragma warning (disable : 4786) // too long name, harmless warning +#endif + +#include <exception> +#include <string> +#include <cstring> + +#define BOOST_ARCHIVE_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/archive/archive_exception.hpp> + +namespace boost { +namespace archive { + +BOOST_ARCHIVE_DECL +unsigned int +archive_exception::append(unsigned int l, const char * a){ + while(l < (sizeof(m_buffer) - 1)){ + char c = *a++; + if('\0' == c) + break; + m_buffer[l++] = c; + } + m_buffer[l] = '\0'; + return l; +} + +BOOST_ARCHIVE_DECL +archive_exception::archive_exception( + exception_code c, + const char * e1, + const char * e2 +) BOOST_NOEXCEPT : + code(c) +{ + unsigned int length = 0; + switch(code){ + case no_exception: + length = append(length, "uninitialized exception"); + break; + case unregistered_class: + length = append(length, "unregistered class"); + if(NULL != e1){ + length = append(length, " - "); + length = append(length, e1); + } + break; + case invalid_signature: + length = append(length, "invalid signature"); + break; + case unsupported_version: + length = append(length, "unsupported version"); + break; + case pointer_conflict: + length = append(length, "pointer conflict"); + break; + case incompatible_native_format: + length = append(length, "incompatible native format"); + if(NULL != e1){ + length = append(length, " - "); + length = append(length, e1); + } + break; + case array_size_too_short: + length = append(length, "array size too short"); + break; + case input_stream_error: + length = append(length, "input stream error"); + if(NULL != e1){ + length = append(length, "-"); + length = append(length, e1); + } + if(NULL != e2){ + length = append(length, "-"); + length = append(length, e2); + } + break; + case invalid_class_name: + length = append(length, "class name too long"); + break; + case unregistered_cast: + length = append(length, "unregistered void cast "); + length = append(length, (NULL != e1) ? e1 : "?"); + length = append(length, "<-"); + length = append(length, (NULL != e2) ? e2 : "?"); + break; + case unsupported_class_version: + length = append(length, "class version "); + length = append(length, (NULL != e1) ? e1 : "<unknown class>"); + break; + case other_exception: + // if get here - it indicates a derived exception + // was sliced by passing by value in catch + length = append(length, "unknown derived exception"); + break; + case multiple_code_instantiation: + length = append(length, "code instantiated in more than one module"); + if(NULL != e1){ + length = append(length, " - "); + length = append(length, e1); + } + break; + case output_stream_error: + length = append(length, "output stream error"); + if(NULL != e1){ + length = append(length, "-"); + length = append(length, e1); + } + if(NULL != e2){ + length = append(length, "-"); + length = append(length, e2); + } + break; + default: + BOOST_ASSERT(false); + length = append(length, "programming error"); + break; + } +} + +BOOST_ARCHIVE_DECL +archive_exception::archive_exception(archive_exception const & oth) BOOST_NOEXCEPT : + std::exception(oth), + code(oth.code) +{ + std::memcpy(m_buffer,oth.m_buffer,sizeof m_buffer); +} + +BOOST_ARCHIVE_DECL +archive_exception::~archive_exception() BOOST_NOEXCEPT_OR_NOTHROW {} + +BOOST_ARCHIVE_DECL const char * +archive_exception::what() const BOOST_NOEXCEPT_OR_NOTHROW { + return m_buffer; +} + +BOOST_ARCHIVE_DECL +archive_exception::archive_exception() BOOST_NOEXCEPT : + code(no_exception) +{} + +} // archive +} // boost diff --git a/src/boost/libs/serialization/src/basic_archive.cpp b/src/boost/libs/serialization/src/basic_archive.cpp new file mode 100644 index 00000000..42da5d2e --- /dev/null +++ b/src/boost/libs/serialization/src/basic_archive.cpp @@ -0,0 +1,90 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// basic_archive.cpp: + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +////////////////////////////////////////////////////////////////////// +// +// objects are stored as +// +// class_id* // -1 for a null pointer +// if a new class id +// [ +// exported key - class name* +// tracking level - always/never +// class version +// ] +// +// if tracking +// [ +// object_id +// ] +// +// [ // if a new object id +// data... +// ] +// +// * required only for pointers - optional for objects + +#define BOOST_ARCHIVE_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/archive/basic_archive.hpp> + +namespace boost { +namespace archive { + +/////////////////////////////////////////////////////////////////////// +// constants used in archive signature +//This should never ever change. note that is not an std::string +// string. +BOOST_SYMBOL_VISIBLE const char * +BOOST_ARCHIVE_SIGNATURE(){ + return "serialization::archive"; +} + +// this should change if the capabilities are added to the library +// such that archives can be created which can't be read by previous +// versions of this library +// 1 - initial version +// 2 - made address tracking optional +// 3 - numerous changes - can't guarentee compatibility with previous versions +// 4 - Boost 1.34 +// added item_version to properly support versioning for collections +// 5 - Boost 1.36 +// changed serialization of collections: adding version even for primitive +// types caused backwards compatibility breaking change in 1.35 +// 6 - Boost 1.41 17 Nov 2009 +// serializing collection sizes as std::size_t +// 7 Boost 1.42 2 Feb 2010 +// error - changed binary version to 16 bits w/o changing library version # +// That is - binary archives are recorded with #6 even though they are +// different from the previous versions. This means that binary archives +// created with versions 1.42 and 1.43 will have to be fixed with a special +// program which fixes the library version # in the header +// Boost 1.43 6 May 2010 +// no change +// 8 - Boost 1.44 +// separated version_type into library_version_type and class_version_type +// changed version_type to be stored as 8 bits. +// 10- fixed base64 output/input. +// 11- not changes +// 12- improved serialization of collections +// 13- simplified visibility, removed Borland, removed pfto +// 14- improved visibility, refactor map/set +// 15- corrections to optional and collection loading +// 16- eliminated dependency on <codecvt> which is buggy in some libraries +// and now officially deprecated in the standard +// 17- Boost 1.68 August 2018 + +BOOST_SYMBOL_VISIBLE library_version_type +BOOST_ARCHIVE_VERSION(){ + return library_version_type(17); +} + +} // namespace archive +} // namespace boost diff --git a/src/boost/libs/serialization/src/basic_iarchive.cpp b/src/boost/libs/serialization/src/basic_iarchive.cpp new file mode 100644 index 00000000..a5455a53 --- /dev/null +++ b/src/boost/libs/serialization/src/basic_iarchive.cpp @@ -0,0 +1,599 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// basic_archive.cpp: + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <boost/config.hpp> // msvc 6.0 needs this to suppress warnings + +#include <boost/assert.hpp> +#include <set> +#include <list> +#include <vector> +#include <cstddef> // size_t, NULL + +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::size_t; +} // namespace std +#endif + +#include <boost/integer_traits.hpp> + +#define BOOST_ARCHIVE_SOURCE +// include this to prevent linker errors when the +// same modules are marked export and import. +#define BOOST_SERIALIZATION_SOURCE +#include <boost/serialization/config.hpp> + +#include <boost/serialization/state_saver.hpp> +#include <boost/serialization/throw_exception.hpp> +#include <boost/serialization/tracking.hpp> + +#include <boost/archive/archive_exception.hpp> +#include <boost/archive/detail/decl.hpp> +#include <boost/archive/basic_archive.hpp> +#include <boost/archive/detail/basic_iserializer.hpp> +#include <boost/archive/detail/basic_pointer_iserializer.hpp> +#include <boost/archive/detail/basic_iarchive.hpp> + +#include <boost/archive/detail/auto_link_archive.hpp> + +using namespace boost::serialization; + +namespace boost { +namespace archive { +namespace detail { + +class basic_iarchive_impl { + friend class basic_iarchive; + library_version_type m_archive_library_version; + unsigned int m_flags; + + ////////////////////////////////////////////////////////////////////// + // information about each serialized object loaded + // indexed on object_id + struct aobject + { + void * address; + bool loaded_as_pointer; + class_id_type class_id; + aobject( + void *a, + class_id_type class_id_ + ) : + address(a), + loaded_as_pointer(false), + class_id(class_id_) + {} + aobject() : + address(NULL), + loaded_as_pointer(false), + class_id(-2) + {} + }; + typedef std::vector<aobject> object_id_vector_type; + object_id_vector_type object_id_vector; + + ////////////////////////////////////////////////////////////////////// + // used to implement the reset_object_address operation. + struct moveable_objects { + object_id_type start; + object_id_type end; + object_id_type recent; + bool is_pointer; + moveable_objects() : + start(0), + end(0), + recent(0), + is_pointer(false) + {} + } m_moveable_objects; + + void reset_object_address( + const void * new_address, + const void *old_address + ); + + ////////////////////////////////////////////////////////////////////// + // used by load object to look up class id given basic_serializer + struct cobject_type + { + const basic_iserializer * m_bis; + const class_id_type m_class_id; + cobject_type( + std::size_t class_id, + const basic_iserializer & bis + ) : + m_bis(& bis), + m_class_id(class_id) + {} + cobject_type(const cobject_type & rhs) : + m_bis(rhs.m_bis), + m_class_id(rhs.m_class_id) + {} + // the following cannot be defined because of the const + // member. This will generate a link error if an attempt + // is made to assign. This should never be necessary + cobject_type & operator=(const cobject_type & rhs); + bool operator<(const cobject_type &rhs) const + { + return *m_bis < *(rhs.m_bis); + } + }; + typedef std::set<cobject_type> cobject_info_set_type; + cobject_info_set_type cobject_info_set; + + ////////////////////////////////////////////////////////////////////// + // information about each serialized class indexed on class_id + class cobject_id + { + public: + cobject_id & operator=(const cobject_id & rhs){ + bis_ptr = rhs.bis_ptr; + bpis_ptr = rhs.bpis_ptr; + file_version = rhs.file_version; + tracking_level = rhs.tracking_level; + initialized = rhs.initialized; + return *this; + } + const basic_iserializer * bis_ptr; + const basic_pointer_iserializer * bpis_ptr; + version_type file_version; + tracking_type tracking_level; + bool initialized; + + cobject_id(const basic_iserializer & bis_) : + bis_ptr(& bis_), + bpis_ptr(NULL), + file_version(0), + tracking_level(track_never), + initialized(false) + {} + cobject_id(const cobject_id &rhs): + bis_ptr(rhs.bis_ptr), + bpis_ptr(rhs.bpis_ptr), + file_version(rhs.file_version), + tracking_level(rhs.tracking_level), + initialized(rhs.initialized) + {} + }; + typedef std::vector<cobject_id> cobject_id_vector_type; + cobject_id_vector_type cobject_id_vector; + + ////////////////////////////////////////////////////////////////////// + // address of the most recent object serialized as a poiner + // whose data itself is now pending serialization + struct pending { + void * object; + const basic_iserializer * bis; + version_type version; + pending() : + object(NULL), + bis(NULL), + version(0) + {} + } m_pending; + + basic_iarchive_impl(unsigned int flags) : + m_archive_library_version(BOOST_ARCHIVE_VERSION()), + m_flags(flags) + {} + void set_library_version(library_version_type archive_library_version){ + m_archive_library_version = archive_library_version; + } + bool + track( + basic_iarchive & ar, + void * & t + ); + void + load_preamble( + basic_iarchive & ar, + cobject_id & co + ); + class_id_type register_type( + const basic_iserializer & bis + ); + + // redirect through virtual functions to load functions for this archive + template<class T> + void load(basic_iarchive & ar, T & t){ + ar.vload(t); + } + +//public: + void + next_object_pointer(void * t){ + m_pending.object = t; + } + void delete_created_pointers(); + class_id_type register_type( + const basic_pointer_iserializer & bpis + ); + void load_object( + basic_iarchive & ar, + void * t, + const basic_iserializer & bis + ); + const basic_pointer_iserializer * load_pointer( + basic_iarchive & ar, + void * & t, + const basic_pointer_iserializer * bpis, + const basic_pointer_iserializer * (*finder)( + const boost::serialization::extended_type_info & type + ) + ); +}; + +inline void +basic_iarchive_impl::reset_object_address( + void const * const new_address, + void const * const old_address +){ + if(m_moveable_objects.is_pointer) + return; + + // this code handles a couple of situations. + // a) where reset_object_address is applied to an untracked object. + // In such a case the call is really superfluous and its really an + // an error. But we don't have access to the types here so we can't + // know that. However, this code will effectively turn this situation + // into a no-op and every thing will work fine - albeat with a small + // execution time penalty. + // b) where the call to reset_object_address doesn't immediatly follow + // the << operator to which it corresponds. This would be a bad idea + // but the code may work anyway. Naturally, a bad practice on the part + // of the programmer but we can't detect it - as above. So maybe we + // can save a few more people from themselves as above. + object_id_type i = m_moveable_objects.recent; + for(; i < m_moveable_objects.end; ++i){ + if(old_address == object_id_vector[i].address) + break; + } + for(; i < m_moveable_objects.end; ++i){ + void const * const this_address = object_id_vector[i].address; + // calculate displacement from this level + // warning - pointer arithmetic on void * is in herently non-portable + // but expected to work on all platforms in current usage + if(this_address > old_address){ + std::size_t member_displacement + = reinterpret_cast<std::size_t>(this_address) + - reinterpret_cast<std::size_t>(old_address); + object_id_vector[i].address = reinterpret_cast<void *>( + reinterpret_cast<std::size_t>(new_address) + member_displacement + ); + } + else{ + std::size_t member_displacement + = reinterpret_cast<std::size_t>(old_address) + - reinterpret_cast<std::size_t>(this_address); + object_id_vector[i].address = reinterpret_cast<void *>( + reinterpret_cast<std::size_t>(new_address) - member_displacement + ); + } + } +} + +inline void +basic_iarchive_impl::delete_created_pointers() +{ + object_id_vector_type::iterator i; + for( + i = object_id_vector.begin(); + i != object_id_vector.end(); + ++i + ){ + if(i->loaded_as_pointer){ + // borland complains without this minor hack + const int j = i->class_id; + const cobject_id & co = cobject_id_vector[j]; + //const cobject_id & co = cobject_id_vector[i->class_id]; + // with the appropriate input serializer, + // delete the indicated object + co.bis_ptr->destroy(i->address); + } + } +} + +inline class_id_type +basic_iarchive_impl::register_type( + const basic_iserializer & bis +){ + class_id_type cid(cobject_info_set.size()); + cobject_type co(cid, bis); + std::pair<cobject_info_set_type::const_iterator, bool> + result = cobject_info_set.insert(co); + + if(result.second){ + cobject_id_vector.push_back(cobject_id(bis)); + BOOST_ASSERT(cobject_info_set.size() == cobject_id_vector.size()); + } + cid = result.first->m_class_id; + // borland complains without this minor hack + const int tid = cid; + cobject_id & coid = cobject_id_vector[tid]; + coid.bpis_ptr = bis.get_bpis_ptr(); + return cid; +} + +void +basic_iarchive_impl::load_preamble( + basic_iarchive & ar, + cobject_id & co +){ + if(! co.initialized){ + if(co.bis_ptr->class_info()){ + class_id_optional_type cid(class_id_type(0)); + load(ar, cid); // to be thrown away + load(ar, co.tracking_level); + load(ar, co.file_version); + } + else{ + // override tracking with indicator from class information + co.tracking_level = co.bis_ptr->tracking(m_flags); + co.file_version = version_type( + co.bis_ptr->version() + ); + } + co.initialized = true; + } +} + +bool +basic_iarchive_impl::track( + basic_iarchive & ar, + void * & t +){ + object_id_type oid; + load(ar, oid); + + // if its a reference to a old object + if(object_id_type(object_id_vector.size()) > oid){ + // we're done + t = object_id_vector[oid].address; + return false; + } + return true; +} + +inline void +basic_iarchive_impl::load_object( + basic_iarchive & ar, + void * t, + const basic_iserializer & bis +){ + m_moveable_objects.is_pointer = false; + serialization::state_saver<bool> ss_is_pointer(m_moveable_objects.is_pointer); + // if its been serialized through a pointer and the preamble's been done + if(t == m_pending.object && & bis == m_pending.bis){ + // read data + (bis.load_object_data)(ar, t, m_pending.version); + return; + } + + const class_id_type cid = register_type(bis); + const int i = cid; + cobject_id & co = cobject_id_vector[i]; + + load_preamble(ar, co); + + // save the current move stack position in case we want to truncate it + boost::serialization::state_saver<object_id_type> ss_start(m_moveable_objects.start); + + // note: extra line used to evade borland issue + const bool tracking = co.tracking_level; + + object_id_type this_id; + m_moveable_objects.start = + this_id = object_id_type(object_id_vector.size()); + + // if we tracked this object when the archive was saved + if(tracking){ + // if it was already read + if(!track(ar, t)) + // we're done + return; + // add a new enty into the tracking list + object_id_vector.push_back(aobject(t, cid)); + // and add an entry for this object + m_moveable_objects.end = object_id_type(object_id_vector.size()); + } + // read data + (bis.load_object_data)(ar, t, co.file_version); + m_moveable_objects.recent = this_id; +} + +inline const basic_pointer_iserializer * +basic_iarchive_impl::load_pointer( + basic_iarchive &ar, + void * & t, + const basic_pointer_iserializer * bpis_ptr, + const basic_pointer_iserializer * (*finder)( + const boost::serialization::extended_type_info & type_ + ) +){ + m_moveable_objects.is_pointer = true; + serialization::state_saver<bool> w(m_moveable_objects.is_pointer); + + class_id_type cid; + load(ar, cid); + + if(NULL_POINTER_TAG == cid){ + t = NULL; + return bpis_ptr; + } + + // if its a new class type - i.e. never been registered + if(class_id_type(cobject_info_set.size()) <= cid){ + // if its either abstract + if(NULL == bpis_ptr + // or polymorphic + || bpis_ptr->get_basic_serializer().is_polymorphic()){ + // is must have been exported + char key[BOOST_SERIALIZATION_MAX_KEY_SIZE]; + class_name_type class_name(key); + load(ar, class_name); + // if it has a class name + const serialization::extended_type_info *eti = NULL; + if(0 != key[0]) + eti = serialization::extended_type_info::find(key); + if(NULL == eti) + boost::serialization::throw_exception( + archive_exception(archive_exception::unregistered_class) + ); + bpis_ptr = (*finder)(*eti); + } + BOOST_ASSERT(NULL != bpis_ptr); + // class_id_type new_cid = register_type(bpis_ptr->get_basic_serializer()); + BOOST_VERIFY(register_type(bpis_ptr->get_basic_serializer()) == cid); + int i = cid; + cobject_id_vector[i].bpis_ptr = bpis_ptr; + } + int i = cid; + cobject_id & co = cobject_id_vector[i]; + bpis_ptr = co.bpis_ptr; + + if (bpis_ptr == NULL) { + boost::serialization::throw_exception( + archive_exception(archive_exception::unregistered_class) + ); + } + + load_preamble(ar, co); + + // extra line to evade borland issue + const bool tracking = co.tracking_level; + // if we're tracking and the pointer has already been read + if(tracking && ! track(ar, t)) + // we're done + return bpis_ptr; + + // save state + serialization::state_saver<object_id_type> w_start(m_moveable_objects.start); + + // allocate space on the heap for the object - to be constructed later + t = bpis_ptr->heap_allocation(); + BOOST_ASSERT(NULL != t); + + if(! tracking){ + bpis_ptr->load_object_ptr(ar, t, co.file_version); + } + else{ + serialization::state_saver<void *> x(m_pending.object); + serialization::state_saver<const basic_iserializer *> y(m_pending.bis); + serialization::state_saver<version_type> z(m_pending.version); + + m_pending.bis = & bpis_ptr->get_basic_serializer(); + m_pending.version = co.file_version; + + // predict next object id to be created + const size_t ui = object_id_vector.size(); + + serialization::state_saver<object_id_type> w_end(m_moveable_objects.end); + + + // add to list of serialized objects so that we can properly handle + // cyclic strucures + object_id_vector.push_back(aobject(t, cid)); + + // remember that that the address of these elements could change + // when we make another call so don't use the address + bpis_ptr->load_object_ptr( + ar, + t, + m_pending.version + ); + object_id_vector[ui].loaded_as_pointer = true; + } + + return bpis_ptr; +} + +} // namespace detail +} // namespace archive +} // namespace boost + +////////////////////////////////////////////////////////////////////// +// implementation of basic_iarchive functions +namespace boost { +namespace archive { +namespace detail { + +BOOST_ARCHIVE_DECL void +basic_iarchive::next_object_pointer(void *t){ + pimpl->next_object_pointer(t); +} + +BOOST_ARCHIVE_DECL +basic_iarchive::basic_iarchive(unsigned int flags) : + pimpl(new basic_iarchive_impl(flags)) +{} + +BOOST_ARCHIVE_DECL +basic_iarchive::~basic_iarchive() +{} + +BOOST_ARCHIVE_DECL void +basic_iarchive::set_library_version(library_version_type archive_library_version){ + pimpl->set_library_version(archive_library_version); +} + +BOOST_ARCHIVE_DECL void +basic_iarchive::reset_object_address( + const void * new_address, + const void * old_address +){ + pimpl->reset_object_address(new_address, old_address); +} + +BOOST_ARCHIVE_DECL void +basic_iarchive::load_object( + void *t, + const basic_iserializer & bis +){ + pimpl->load_object(*this, t, bis); +} + +// load a pointer object +BOOST_ARCHIVE_DECL const basic_pointer_iserializer * +basic_iarchive::load_pointer( + void * &t, + const basic_pointer_iserializer * bpis_ptr, + const basic_pointer_iserializer * (*finder)( + const boost::serialization::extended_type_info & type_ + ) + +){ + return pimpl->load_pointer(*this, t, bpis_ptr, finder); +} + +BOOST_ARCHIVE_DECL void +basic_iarchive::register_basic_serializer(const basic_iserializer & bis){ + pimpl->register_type(bis); +} + +BOOST_ARCHIVE_DECL void +basic_iarchive::delete_created_pointers() +{ + pimpl->delete_created_pointers(); +} + +BOOST_ARCHIVE_DECL boost::archive::library_version_type +basic_iarchive::get_library_version() const{ + return pimpl->m_archive_library_version; +} + +BOOST_ARCHIVE_DECL unsigned int +basic_iarchive::get_flags() const{ + return pimpl->m_flags; +} + +} // namespace detail +} // namespace archive +} // namespace boost diff --git a/src/boost/libs/serialization/src/basic_iserializer.cpp b/src/boost/libs/serialization/src/basic_iserializer.cpp new file mode 100644 index 00000000..3898a6a7 --- /dev/null +++ b/src/boost/libs/serialization/src/basic_iserializer.cpp @@ -0,0 +1,34 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// basic_iserializer.cpp: + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <cstddef> // NULL + +#define BOOST_ARCHIVE_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/archive/detail/basic_iserializer.hpp> + +namespace boost { +namespace archive { +namespace detail { + +BOOST_ARCHIVE_DECL +basic_iserializer::basic_iserializer( + const boost::serialization::extended_type_info & eti +) : + basic_serializer(eti), + m_bpis(NULL) +{} + +BOOST_ARCHIVE_DECL +basic_iserializer::~basic_iserializer(){} + +} // namespace detail +} // namespace archive +} // namespace boost diff --git a/src/boost/libs/serialization/src/basic_oarchive.cpp b/src/boost/libs/serialization/src/basic_oarchive.cpp new file mode 100644 index 00000000..653260c3 --- /dev/null +++ b/src/boost/libs/serialization/src/basic_oarchive.cpp @@ -0,0 +1,470 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// basic_oarchive.cpp: + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <boost/config.hpp> // msvc 6.0 needs this for warning suppression + +#include <boost/assert.hpp> +#include <set> +#include <cstddef> // NULL + +#include <boost/limits.hpp> + +// including this here to work around an ICC in intel 7.0 +// normally this would be part of basic_oarchive.hpp below. +#define BOOST_ARCHIVE_SOURCE +// include this to prevent linker errors when the +// same modules are marked export and import. +#define BOOST_SERIALIZATION_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/serialization/state_saver.hpp> +#include <boost/serialization/throw_exception.hpp> +#include <boost/serialization/extended_type_info.hpp> + +#include <boost/archive/detail/decl.hpp> +#include <boost/archive/basic_archive.hpp> +#include <boost/archive/detail/basic_oserializer.hpp> +#include <boost/archive/detail/basic_pointer_oserializer.hpp> +#include <boost/archive/detail/basic_oarchive.hpp> +#include <boost/archive/archive_exception.hpp> + +#ifdef BOOST_MSVC +# pragma warning(push) +# pragma warning(disable : 4251 4231 4660 4275) +#endif + +using namespace boost::serialization; + +namespace boost { +namespace archive { +namespace detail { + +class basic_oarchive_impl { + friend class basic_oarchive; + unsigned int m_flags; + + ////////////////////////////////////////////////////////////////////// + // information about each serialized object saved + // keyed on address, class_id + struct aobject + { + const void * address; + class_id_type class_id; + object_id_type object_id; + + bool operator<(const aobject &rhs) const + { + BOOST_ASSERT(NULL != address); + BOOST_ASSERT(NULL != rhs.address); + if( address < rhs.address ) + return true; + if( address > rhs.address ) + return false; + return class_id < rhs.class_id; + } + aobject & operator=(const aobject & rhs) + { + address = rhs.address; + class_id = rhs.class_id; + object_id = rhs.object_id; + return *this; + } + aobject( + const void *a, + class_id_type class_id_, + object_id_type object_id_ + ) : + address(a), + class_id(class_id_), + object_id(object_id_) + {} + aobject() : address(NULL){} + }; + // keyed on class_id, address + typedef std::set<aobject> object_set_type; + object_set_type object_set; + + ////////////////////////////////////////////////////////////////////// + // information about each serialized class saved + // keyed on type_info + struct cobject_type + { + const basic_oserializer * m_bos_ptr; + const class_id_type m_class_id; + bool m_initialized; + cobject_type( + std::size_t class_id, + const basic_oserializer & bos + ) : + m_bos_ptr(& bos), + m_class_id(class_id), + m_initialized(false) + {} + cobject_type(const basic_oserializer & bos) : + m_bos_ptr(& bos), + m_initialized(false) + {} + cobject_type( + const cobject_type & rhs + ) : + m_bos_ptr(rhs.m_bos_ptr), + m_class_id(rhs.m_class_id), + m_initialized(rhs.m_initialized) + {} + // the following cannot be defined because of the const + // member. This will generate a link error if an attempt + // is made to assign. This should never be necessary + // use this only for lookup argument + cobject_type & operator=(const cobject_type &rhs); + bool operator<(const cobject_type &rhs) const { + return *m_bos_ptr < *(rhs.m_bos_ptr); + } + }; + // keyed on type_info + typedef std::set<cobject_type> cobject_info_set_type; + cobject_info_set_type cobject_info_set; + + // list of objects initially stored as pointers - used to detect errors + // keyed on object id + std::set<object_id_type> stored_pointers; + + // address of the most recent object serialized as a poiner + // whose data itself is now pending serialization + const void * pending_object; + const basic_oserializer * pending_bos; + + basic_oarchive_impl(unsigned int flags) : + m_flags(flags), + pending_object(NULL), + pending_bos(NULL) + {} + + const cobject_type & + find(const basic_oserializer & bos); + const basic_oserializer * + find(const serialization::extended_type_info &ti) const; + +//public: + const cobject_type & + register_type(const basic_oserializer & bos); + void save_object( + basic_oarchive & ar, + const void *t, + const basic_oserializer & bos + ); + void save_pointer( + basic_oarchive & ar, + const void * t, + const basic_pointer_oserializer * bpos + ); +}; + +////////////////////////////////////////////////////////////////////// +// basic_oarchive implementation functions + +// given a type_info - find its bos +// return NULL if not found +inline const basic_oserializer * +basic_oarchive_impl::find(const serialization::extended_type_info & ti) const { + #ifdef BOOST_MSVC + # pragma warning(push) + # pragma warning(disable : 4511 4512) + #endif + class bosarg : + public basic_oserializer + { + bool class_info() const { + BOOST_ASSERT(false); + return false; + } + // returns true if objects should be tracked + bool tracking(const unsigned int) const { + BOOST_ASSERT(false); + return false; + } + // returns class version + version_type version() const { + BOOST_ASSERT(false); + return version_type(0); + } + // returns true if this class is polymorphic + bool is_polymorphic() const{ + BOOST_ASSERT(false); + return false; + } + void save_object_data( + basic_oarchive & /*ar*/, const void * /*x*/ + ) const { + BOOST_ASSERT(false); + } + public: + bosarg(const serialization::extended_type_info & eti) : + boost::archive::detail::basic_oserializer(eti) + {} + }; + #ifdef BOOST_MSVC + #pragma warning(pop) + #endif + bosarg bos(ti); + cobject_info_set_type::const_iterator cit + = cobject_info_set.find(cobject_type(bos)); + // it should already have been "registered" - see below + if(cit == cobject_info_set.end()){ + // if an entry is not found in the table it is because a pointer + // of a derived class has been serialized through its base class + // but the derived class hasn't been "registered" + return NULL; + } + // return pointer to the real class + return cit->m_bos_ptr; +} + +inline const basic_oarchive_impl::cobject_type & +basic_oarchive_impl::find(const basic_oserializer & bos) +{ + std::pair<cobject_info_set_type::iterator, bool> cresult = + cobject_info_set.insert(cobject_type(cobject_info_set.size(), bos)); + return *(cresult.first); +} + +inline const basic_oarchive_impl::cobject_type & +basic_oarchive_impl::register_type( + const basic_oserializer & bos +){ + cobject_type co(cobject_info_set.size(), bos); + std::pair<cobject_info_set_type::const_iterator, bool> + result = cobject_info_set.insert(co); + return *(result.first); +} + +inline void +basic_oarchive_impl::save_object( + basic_oarchive & ar, + const void *t, + const basic_oserializer & bos +){ + // if its been serialized through a pointer and the preamble's been done + if(t == pending_object && pending_bos == & bos){ + // just save the object data + ar.end_preamble(); + (bos.save_object_data)(ar, t); + return; + } + + // get class information for this object + const cobject_type & co = register_type(bos); + if(bos.class_info()){ + if( ! co.m_initialized){ + ar.vsave(class_id_optional_type(co.m_class_id)); + ar.vsave(tracking_type(bos.tracking(m_flags))); + ar.vsave(version_type(bos.version())); + (const_cast<cobject_type &>(co)).m_initialized = true; + } + } + + // we're not tracking this type of object + if(! bos.tracking(m_flags)){ + // just windup the preamble - no object id to write + ar.end_preamble(); + // and save the data + (bos.save_object_data)(ar, t); + return; + } + + // look for an existing object id + object_id_type oid(object_set.size()); + // lookup to see if this object has already been written to the archive + basic_oarchive_impl::aobject ao(t, co.m_class_id, oid); + std::pair<basic_oarchive_impl::object_set_type::const_iterator, bool> + aresult = object_set.insert(ao); + oid = aresult.first->object_id; + + // if its a new object + if(aresult.second){ + // write out the object id + ar.vsave(oid); + ar.end_preamble(); + // and data + (bos.save_object_data)(ar, t); + return; + } + + // check that it wasn't originally stored through a pointer + if(stored_pointers.end() != stored_pointers.find(oid)){ + // this has to be a user error. loading such an archive + // would create duplicate objects + boost::serialization::throw_exception( + archive_exception(archive_exception::pointer_conflict) + ); + } + // just save the object id + ar.vsave(object_reference_type(oid)); + ar.end_preamble(); + return; +} + +// save a pointer to an object instance +inline void +basic_oarchive_impl::save_pointer( + basic_oarchive & ar, + const void * t, + const basic_pointer_oserializer * bpos_ptr +){ + const basic_oserializer & bos = bpos_ptr->get_basic_serializer(); + std::size_t original_count = cobject_info_set.size(); + const cobject_type & co = register_type(bos); + if(! co.m_initialized){ + ar.vsave(co.m_class_id); + // if its a previously unregistered class + if((cobject_info_set.size() > original_count)){ + if(bos.is_polymorphic()){ + const serialization::extended_type_info *eti = & bos.get_eti(); + const char * key = NULL; + if(NULL != eti) + key = eti->get_key(); + if(NULL != key){ + // the following is required by IBM C++ compiler which + // makes a copy when passing a non-const to a const. This + // is permitted by the standard but rarely seen in practice + const class_name_type cn(key); + if(cn.size() > (BOOST_SERIALIZATION_MAX_KEY_SIZE - 1)) + boost::serialization::throw_exception( + boost::archive::archive_exception( + boost::archive::archive_exception:: + invalid_class_name) + ); + // write out the external class identifier + ar.vsave(cn); + } + else + // without an external class name + // we won't be able to de-serialize it so bail now + boost::serialization::throw_exception( + archive_exception(archive_exception::unregistered_class) + ); + } + } + if(bos.class_info()){ + ar.vsave(tracking_type(bos.tracking(m_flags))); + ar.vsave(version_type(bos.version())); + } + (const_cast<cobject_type &>(co)).m_initialized = true; + } + else{ + ar.vsave(class_id_reference_type(co.m_class_id)); + } + + // if we're not tracking + if(! bos.tracking(m_flags)){ + // just save the data itself + ar.end_preamble(); + serialization::state_saver<const void *> x(pending_object); + serialization::state_saver<const basic_oserializer *> y(pending_bos); + pending_object = t; + pending_bos = & bpos_ptr->get_basic_serializer(); + bpos_ptr->save_object_ptr(ar, t); + return; + } + + object_id_type oid(object_set.size()); + // lookup to see if this object has already been written to the archive + basic_oarchive_impl::aobject ao(t, co.m_class_id, oid); + std::pair<basic_oarchive_impl::object_set_type::const_iterator, bool> + aresult = object_set.insert(ao); + oid = aresult.first->object_id; + // if the saved object already exists + if(! aresult.second){ + // append the object id to he preamble + ar.vsave(object_reference_type(oid)); + // and windup. + ar.end_preamble(); + return; + } + + // append id of this object to preamble + ar.vsave(oid); + ar.end_preamble(); + + // and save the object itself + serialization::state_saver<const void *> x(pending_object); + serialization::state_saver<const basic_oserializer *> y(pending_bos); + pending_object = t; + pending_bos = & bpos_ptr->get_basic_serializer(); + bpos_ptr->save_object_ptr(ar, t); + // add to the set of object initially stored through pointers + stored_pointers.insert(oid); +} + +} // namespace detail +} // namespace archive +} // namespace boost + +////////////////////////////////////////////////////////////////////// +// implementation of basic_oarchive functions + +namespace boost { +namespace archive { +namespace detail { + +BOOST_ARCHIVE_DECL +basic_oarchive::basic_oarchive(unsigned int flags) + : pimpl(new basic_oarchive_impl(flags)) +{} + +BOOST_ARCHIVE_DECL +basic_oarchive::~basic_oarchive() +{} + +BOOST_ARCHIVE_DECL void +basic_oarchive::save_object( + const void *x, + const basic_oserializer & bos +){ + pimpl->save_object(*this, x, bos); +} + +BOOST_ARCHIVE_DECL void +basic_oarchive::save_pointer( + const void * t, + const basic_pointer_oserializer * bpos_ptr +){ + pimpl->save_pointer(*this, t, bpos_ptr); +} + +BOOST_ARCHIVE_DECL void +basic_oarchive::register_basic_serializer(const basic_oserializer & bos){ + pimpl->register_type(bos); +} + +BOOST_ARCHIVE_DECL library_version_type +basic_oarchive::get_library_version() const{ + return BOOST_ARCHIVE_VERSION(); +} + +BOOST_ARCHIVE_DECL unsigned int +basic_oarchive::get_flags() const{ + return pimpl->m_flags; +} + +BOOST_ARCHIVE_DECL void +basic_oarchive::end_preamble(){ +} + +BOOST_ARCHIVE_DECL helper_collection & +basic_oarchive::get_helper_collection(){ + return *this; +} + +} // namespace detail +} // namespace archive +} // namespace boost + +#ifdef BOOST_MSVC +#pragma warning(pop) +#endif diff --git a/src/boost/libs/serialization/src/basic_oserializer.cpp b/src/boost/libs/serialization/src/basic_oserializer.cpp new file mode 100644 index 00000000..afe08c4b --- /dev/null +++ b/src/boost/libs/serialization/src/basic_oserializer.cpp @@ -0,0 +1,34 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// basic_oserializer.cpp: + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <cstddef> // NULL + +#define BOOST_ARCHIVE_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/archive/detail/basic_oserializer.hpp> + +namespace boost { +namespace archive { +namespace detail { + +BOOST_ARCHIVE_DECL +basic_oserializer::basic_oserializer( + const boost::serialization::extended_type_info & eti +) : + basic_serializer(eti), + m_bpos(NULL) +{} + +BOOST_ARCHIVE_DECL +basic_oserializer::~basic_oserializer(){} + +} // namespace detail +} // namespace archive +} // namespace boost diff --git a/src/boost/libs/serialization/src/basic_pointer_iserializer.cpp b/src/boost/libs/serialization/src/basic_pointer_iserializer.cpp new file mode 100644 index 00000000..7cf63f30 --- /dev/null +++ b/src/boost/libs/serialization/src/basic_pointer_iserializer.cpp @@ -0,0 +1,31 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// basic_pointer_iserializer.cpp: + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#define BOOST_ARCHIVE_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/archive/detail/basic_pointer_iserializer.hpp> + +namespace boost { +namespace archive { +namespace detail { + +BOOST_ARCHIVE_DECL +basic_pointer_iserializer::basic_pointer_iserializer( + const boost::serialization::extended_type_info & eti +) : + basic_serializer(eti) +{} + +BOOST_ARCHIVE_DECL +basic_pointer_iserializer::~basic_pointer_iserializer() {} + +} // namespace detail +} // namespace archive +} // namespace boost diff --git a/src/boost/libs/serialization/src/basic_pointer_oserializer.cpp b/src/boost/libs/serialization/src/basic_pointer_oserializer.cpp new file mode 100644 index 00000000..e86f7b78 --- /dev/null +++ b/src/boost/libs/serialization/src/basic_pointer_oserializer.cpp @@ -0,0 +1,31 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// basic_pointer_oserializer.cpp: + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#define BOOST_ARCHIVE_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/archive/detail/basic_pointer_oserializer.hpp> + +namespace boost { +namespace archive { +namespace detail { + +BOOST_ARCHIVE_DECL +basic_pointer_oserializer::basic_pointer_oserializer( + const boost::serialization::extended_type_info & eti +) : + basic_serializer(eti) +{} + +BOOST_ARCHIVE_DECL +basic_pointer_oserializer::~basic_pointer_oserializer() {} + +} // namespace detail +} // namespace archive +} // namespace boost diff --git a/src/boost/libs/serialization/src/basic_serializer_map.cpp b/src/boost/libs/serialization/src/basic_serializer_map.cpp new file mode 100644 index 00000000..5b791077 --- /dev/null +++ b/src/boost/libs/serialization/src/basic_serializer_map.cpp @@ -0,0 +1,112 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// serializer_map.cpp: + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#if (defined _MSC_VER) && (_MSC_VER == 1200) +# pragma warning (disable : 4786) // too long name, harmless warning +#endif + +#include <set> +#include <utility> + +#define BOOST_ARCHIVE_SOURCE +// include this to prevent linker errors when the +// same modules are marked export and import. +#define BOOST_SERIALIZATION_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/serialization/throw_exception.hpp> + +#include <boost/archive/archive_exception.hpp> +#include <boost/archive/detail/basic_serializer.hpp> +#include <boost/archive/detail/basic_serializer_map.hpp> + +namespace boost { + namespace serialization { + class extended_type_info; + } +namespace archive { +namespace detail { + +bool +basic_serializer_map::type_info_pointer_compare::operator()( + const basic_serializer * lhs, const basic_serializer * rhs +) const { + return *lhs < *rhs; +} + +BOOST_ARCHIVE_DECL bool +basic_serializer_map::insert(const basic_serializer * bs){ + // attempt to insert serializer into it's map + // the following is commented out - rather than being just + // deleted as a reminder not to try this. + + // const std::pair<map_type::iterator, bool> result = + m_map.insert(bs); + + // At first it seemed like a good idea. It enforced the + // idea that a type be exported from at most one code module + // (DLL or mainline). This would enforce a "one definition rule" + // across code modules. This seems a good idea to me. + // But it seems that it's just too hard for many users to implement. + + // Ideally, I would like to make this exception a warning - + // but there isn't anyway to do that. + + // if this fails, it's because it's been instantiated + // in multiple modules - DLLS - a recipe for problems. + // So trap this here + // if(!result.second){ + // boost::serialization::throw_exception( + // archive_exception( + // archive_exception::multiple_code_instantiation, + // bs->get_debug_info() + // ) + // ); + // } + return true; +} + +BOOST_ARCHIVE_DECL void +basic_serializer_map::erase(const basic_serializer * bs){ + map_type::iterator it = m_map.begin(); + map_type::iterator it_end = m_map.end(); + + while(it != it_end){ + // note item 9 from Effective STL !!! it++ + if(*it == bs) + m_map.erase(it++); + else + it++; + } + // note: we can't do this since some of the eti records + // we're pointing to might be expired and the comparison + // won't work. Leave this as a reminder not to "optimize" this. + //it = m_map.find(bs); + //assert(it != m_map.end()); + //if(*it == bs) + // m_map.erase(it); +} +BOOST_ARCHIVE_DECL const basic_serializer * +basic_serializer_map::find( + const boost::serialization::extended_type_info & eti +) const { + const basic_serializer_arg bs(eti); + map_type::const_iterator it; + it = m_map.find(& bs); + if(it == m_map.end()){ + BOOST_ASSERT(false); + return 0; + } + return *it; +} + +} // namespace detail +} // namespace archive +} // namespace boost + diff --git a/src/boost/libs/serialization/src/basic_text_iprimitive.cpp b/src/boost/libs/serialization/src/basic_text_iprimitive.cpp new file mode 100644 index 00000000..c0b7f766 --- /dev/null +++ b/src/boost/libs/serialization/src/basic_text_iprimitive.cpp @@ -0,0 +1,29 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// basic_text_iprimitive.cpp: + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#if (defined _MSC_VER) && (_MSC_VER == 1200) +# pragma warning (disable : 4786) // too long name, harmless warning +#endif + +#include <istream> + +#define BOOST_ARCHIVE_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/archive/detail/auto_link_archive.hpp> +#include <boost/archive/impl/basic_text_iprimitive.ipp> + +namespace boost { +namespace archive { + +// explicitly instantiate for this type of text stream +template class basic_text_iprimitive<std::istream> ; + +} // namespace archive +} // namespace boost diff --git a/src/boost/libs/serialization/src/basic_text_oprimitive.cpp b/src/boost/libs/serialization/src/basic_text_oprimitive.cpp new file mode 100644 index 00000000..60166229 --- /dev/null +++ b/src/boost/libs/serialization/src/basic_text_oprimitive.cpp @@ -0,0 +1,29 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// basic_text_oprimitive.cpp: + +// (C) Copyright 2004 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#if (defined _MSC_VER) && (_MSC_VER == 1200) +# pragma warning (disable : 4786) // too long name, harmless warning +#endif + +#include <ostream> + +#define BOOST_ARCHIVE_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/archive/detail/auto_link_archive.hpp> +#include <boost/archive/impl/basic_text_oprimitive.ipp> + +namespace boost { +namespace archive { + +// explicitly instantiate for this type of text stream +template class basic_text_oprimitive<std::ostream> ; + +} // namespace archive +} // namespace boost diff --git a/src/boost/libs/serialization/src/basic_text_wiprimitive.cpp b/src/boost/libs/serialization/src/basic_text_wiprimitive.cpp new file mode 100644 index 00000000..28250007 --- /dev/null +++ b/src/boost/libs/serialization/src/basic_text_wiprimitive.cpp @@ -0,0 +1,36 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// basic_text_wiprimitive.cpp: + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <istream> + +#include <boost/config.hpp> + +#ifdef BOOST_NO_STD_WSTREAMBUF +#error "wide char i/o not supported on this platform" +#else + +#if (defined _MSC_VER) && (_MSC_VER == 1200) +# pragma warning (disable : 4786) // too long name, harmless warning +#endif + +#define BOOST_WARCHIVE_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/archive/detail/auto_link_warchive.hpp> +#include <boost/archive/impl/basic_text_iprimitive.ipp> + +namespace boost { +namespace archive { + +template class basic_text_iprimitive<std::wistream> ; + +} // namespace archive +} // namespace boost + +#endif // BOOST_NO_STD_WSTREAMBUF diff --git a/src/boost/libs/serialization/src/basic_text_woprimitive.cpp b/src/boost/libs/serialization/src/basic_text_woprimitive.cpp new file mode 100644 index 00000000..6c0caa97 --- /dev/null +++ b/src/boost/libs/serialization/src/basic_text_woprimitive.cpp @@ -0,0 +1,36 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// basic_text_woprimitive.cpp: + +// (C) Copyright 2004 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <ostream> + +#include <boost/config.hpp> + +#ifdef BOOST_NO_STD_WSTREAMBUF +#error "wide char i/o not supported on this platform" +#else + +#if (defined _MSC_VER) && (_MSC_VER == 1200) +# pragma warning (disable : 4786) // too long name, harmless warning +#endif + +#define BOOST_WARCHIVE_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/archive/detail/auto_link_warchive.hpp> +#include <boost/archive/impl/basic_text_oprimitive.ipp> + +namespace boost { +namespace archive { + +template class basic_text_oprimitive<std::wostream> ; + +} // namespace archive +} // namespace boost + +#endif // BOOST_NO_STD_WSTREAMBUF diff --git a/src/boost/libs/serialization/src/basic_xml_archive.cpp b/src/boost/libs/serialization/src/basic_xml_archive.cpp new file mode 100644 index 00000000..23ab1819 --- /dev/null +++ b/src/boost/libs/serialization/src/basic_xml_archive.cpp @@ -0,0 +1,52 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// basic_xml_archive.cpp: + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#define BOOST_ARCHIVE_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/archive/basic_xml_archive.hpp> + +namespace boost { +namespace archive { + +BOOST_SYMBOL_VISIBLE const char * +BOOST_ARCHIVE_XML_OBJECT_ID(){ + return "object_id"; +} +BOOST_SYMBOL_VISIBLE const char * +BOOST_ARCHIVE_XML_OBJECT_REFERENCE(){ + return "object_id_reference"; +} +BOOST_SYMBOL_VISIBLE const char * +BOOST_ARCHIVE_XML_CLASS_ID(){ + return "class_id"; +} +BOOST_SYMBOL_VISIBLE const char * +BOOST_ARCHIVE_XML_CLASS_ID_REFERENCE(){ + return "class_id_reference"; +} +BOOST_SYMBOL_VISIBLE const char * +BOOST_ARCHIVE_XML_CLASS_NAME(){ + return "class_name"; +} +BOOST_SYMBOL_VISIBLE const char * +BOOST_ARCHIVE_XML_TRACKING(){ + return "tracking_level"; +} +BOOST_SYMBOL_VISIBLE const char * +BOOST_ARCHIVE_XML_VERSION(){ + return "version"; +} +BOOST_SYMBOL_VISIBLE const char * +BOOST_ARCHIVE_XML_SIGNATURE(){ + return "signature"; +} + +}// namespace archive +}// namespace boost diff --git a/src/boost/libs/serialization/src/basic_xml_grammar.ipp b/src/boost/libs/serialization/src/basic_xml_grammar.ipp new file mode 100644 index 00000000..dcec1cc6 --- /dev/null +++ b/src/boost/libs/serialization/src/basic_xml_grammar.ipp @@ -0,0 +1,468 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// basic_xml_grammar.ipp: + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#if (defined _MSC_VER) && (_MSC_VER == 1200) +# pragma warning (disable : 4786) // too long name, harmless warning +#endif + +#include <istream> +#include <algorithm> +#include <boost/config.hpp> // typename + +#ifdef BOOST_MSVC +# pragma warning(push) +# pragma warning(disable : 4244 4511 4512) +#endif + +#include <cerrno> // errno +#include <cstring> // strerror(errno) + +// spirit stuff +#include <boost/spirit/include/classic_operators.hpp> +#include <boost/spirit/include/classic_actions.hpp> +#include <boost/spirit/include/classic_numerics.hpp> + +#ifdef BOOST_MSVC +#pragma warning(pop) +#endif + +// for head_iterator test +#include <boost/function.hpp> + +#include <boost/io/ios_state.hpp> +#include <boost/serialization/throw_exception.hpp> +#include <boost/archive/impl/basic_xml_grammar.hpp> +#include <boost/archive/xml_archive_exception.hpp> +#include <boost/archive/basic_xml_archive.hpp> +#include <boost/archive/iterators/xml_unescape.hpp> + +using namespace boost::spirit::classic; + +namespace boost { +namespace archive { + +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// template code for basic_xml_grammar of both wchar_t and char types + +namespace xml { // anonymous + +#ifdef BOOST_MSVC +# pragma warning(push) +# pragma warning(disable : 4511 4512) +#endif + +template<class T> +struct assign_impl { + T & t; + void operator()(const T t_) const { + t = t_; + } + assign_impl(T & t_) + : t(t_) + {} +}; + +template<> +struct assign_impl<std::string> { + std::string & t; + void operator()( + std::string::const_iterator b, + std::string::const_iterator e + ) const { + t.resize(0); + while(b != e){ + t += * b; + ++b; + } + } + assign_impl<std::string> & operator=( + assign_impl<std::string> & rhs + ); + assign_impl(std::string & t_) + : t(t_) + {} +}; + +#ifndef BOOST_NO_STD_WSTRING +template<> +struct assign_impl<std::wstring> { + std::wstring & t; + void operator()( + std::wstring::const_iterator b, + std::wstring::const_iterator e + ) const { + t.resize(0); + while(b != e){ + t += * b; + ++b; + } + } + assign_impl(std::wstring & t_) + : t(t_) + {} +}; +#endif + +template<class T> +assign_impl<T> assign_object(T &t){ + return assign_impl<T>(t); +} + +struct assign_level { + tracking_type & tracking_level; + void operator()(const unsigned int tracking_level_) const { + tracking_level = (0 == tracking_level_) ? false : true; + } + assign_level(tracking_type & tracking_level_) + : tracking_level(tracking_level_) + {} +}; + +template<class String, class Iterator> +struct append_string { + String & contents; + void operator()(Iterator start, Iterator end) const { + #if 0 + typedef boost::archive::iterators::xml_unescape<Iterator> translator; + contents.append( + translator(BOOST_MAKE_PFTO_WRAPPER(start)), + translator(BOOST_MAKE_PFTO_WRAPPER(end)) + ); + #endif + contents.append(start, end); + } + append_string(String & contents_) + : contents(contents_) + {} +}; + +template<class String> +struct append_char { + String & contents; + void operator()(const unsigned int char_value) const { + contents += static_cast<typename String::value_type>(char_value); + } + append_char(String & contents_) + : contents(contents_) + {} +}; + +template<class String, unsigned int c> +struct append_lit { + String & contents; + template<class X, class Y> + void operator()(const X & /*x*/, const Y & /*y*/) const { + const typename String::value_type z = c; + contents += z; + } + append_lit(String & contents_) + : contents(contents_) + {} +}; + +#ifdef BOOST_MSVC +#pragma warning(pop) +#endif + +} // namespace anonymous + +template<class CharType> +bool basic_xml_grammar<CharType>::my_parse( + typename basic_xml_grammar<CharType>::IStream & is, + const rule_t & rule_, + CharType delimiter +) const { + if(is.fail()){ + return false; + } + + is >> std::noskipws; + + std::basic_string<CharType> arg; + + for(;;){ + CharType result; + is.get(result); + if(is.fail()){ + boost::serialization::throw_exception( + boost::archive::archive_exception( + archive_exception::input_stream_error, + std::strerror(errno) + ) + ); + } + if(is.eof()) + return false; + arg += result; + if(result == delimiter) + break; + } + + // read just one more character. This will be the newline after the tag + // this is so that the next operation will return fail if the archive + // is terminated. This will permit the archive to be used for debug + // and transaction data logging in the standard way. + + parse_info<typename std::basic_string<CharType>::iterator> + result = boost::spirit::classic::parse(arg.begin(), arg.end(), rule_); + return result.hit; +} + +template<class CharType> +bool basic_xml_grammar<CharType>::parse_start_tag( + typename basic_xml_grammar<CharType>::IStream & is +){ + rv.class_name.resize(0); + return my_parse(is, STag); +} + +template<class CharType> +bool basic_xml_grammar<CharType>::parse_end_tag(IStream & is) const { + return my_parse(is, ETag); +} + +template<class CharType> +bool basic_xml_grammar<CharType>::parse_string(IStream & is, StringType & s){ + rv.contents.resize(0); + bool result = my_parse(is, content, '<'); + // note: unget caused a problem with dinkumware. replace with + // is.unget(); + // putback another delimiter instead + is.putback('<'); + if(result) + s = rv.contents; + return result; +} + +template<class CharType> +basic_xml_grammar<CharType>::basic_xml_grammar(){ + init_chset(); + + S = + +(Sch) + ; + + // refactoring to workaround template depth on darwin + NameHead = (Letter | '_' | ':'); + NameTail = *NameChar ; + Name = + NameHead >> NameTail + ; + + Eq = + !S >> '=' >> !S + ; + + AttributeList = + *(S >> Attribute) + ; + + STag = + !S + >> '<' + >> Name [xml::assign_object(rv.object_name)] + >> AttributeList + >> !S + >> '>' + ; + + ETag = + !S + >> "</" + >> Name [xml::assign_object(rv.object_name)] + >> !S + >> '>' + ; + + // refactoring to workaround template depth on darwin + CharDataChars = +(anychar_p - chset_p(L"&<")); + CharData = + CharDataChars [ + xml::append_string< + StringType, + typename std::basic_string<CharType>::const_iterator + >(rv.contents) + ] + ; + + // slight factoring works around ICE in msvc 6.0 + CharRef1 = + str_p(L"&#") >> uint_p [xml::append_char<StringType>(rv.contents)] >> L';' + ; + CharRef2 = + str_p(L"&#x") >> hex_p [xml::append_char<StringType>(rv.contents)] >> L';' + ; + CharRef = CharRef1 | CharRef2 ; + + AmpRef = str_p(L"&")[xml::append_lit<StringType, L'&'>(rv.contents)]; + LTRef = str_p(L"<")[xml::append_lit<StringType, L'<'>(rv.contents)]; + GTRef = str_p(L">")[xml::append_lit<StringType, L'>'>(rv.contents)]; + AposRef = str_p(L"'")[xml::append_lit<StringType, L'\''>(rv.contents)]; + QuoteRef = str_p(L""")[xml::append_lit<StringType, L'"'>(rv.contents)]; + + Reference = + AmpRef + | LTRef + | GTRef + | AposRef + | QuoteRef + | CharRef + ; + + content = + L"<" // should be end_p + | +(Reference | CharData) >> L"<" + ; + + ClassIDAttribute = + str_p(BOOST_ARCHIVE_XML_CLASS_ID()) >> NameTail + >> Eq + >> L'"' + >> int_p [xml::assign_object(rv.class_id)] + >> L'"' + ; + + ObjectIDAttribute = ( + str_p(BOOST_ARCHIVE_XML_OBJECT_ID()) + | + str_p(BOOST_ARCHIVE_XML_OBJECT_REFERENCE()) + ) + >> NameTail + >> Eq + >> L'"' + >> L'_' + >> uint_p [xml::assign_object(rv.object_id)] + >> L'"' + ; + + AmpName = str_p(L"&")[xml::append_lit<StringType, L'&'>(rv.class_name)]; + LTName = str_p(L"<")[xml::append_lit<StringType, L'<'>(rv.class_name)]; + GTName = str_p(L">")[xml::append_lit<StringType, L'>'>(rv.class_name)]; + ClassNameChar = + AmpName + | LTName + | GTName + | (anychar_p - chset_p(L"\"")) [xml::append_char<StringType>(rv.class_name)] + ; + + ClassName = + * ClassNameChar + ; + + ClassNameAttribute = + str_p(BOOST_ARCHIVE_XML_CLASS_NAME()) + >> Eq + >> L'"' + >> ClassName + >> L'"' + ; + + TrackingAttribute = + str_p(BOOST_ARCHIVE_XML_TRACKING()) + >> Eq + >> L'"' + >> uint_p [xml::assign_level(rv.tracking_level)] + >> L'"' + ; + + VersionAttribute = + str_p(BOOST_ARCHIVE_XML_VERSION()) + >> Eq + >> L'"' + >> uint_p [xml::assign_object(rv.version)] + >> L'"' + ; + + UnusedAttribute = + Name + >> Eq + >> L'"' + >> !CharData + >> L'"' + ; + + Attribute = + ClassIDAttribute + | ObjectIDAttribute + | ClassNameAttribute + | TrackingAttribute + | VersionAttribute + | UnusedAttribute + ; + + XMLDeclChars = *(anychar_p - chset_p(L"?>")); + XMLDecl = + !S + >> str_p(L"<?xml") + >> S + >> str_p(L"version") + >> Eq + >> str_p(L"\"1.0\"") + >> XMLDeclChars + >> !S + >> str_p(L"?>") + ; + + DocTypeDeclChars = *(anychar_p - chset_p(L">")); + DocTypeDecl = + !S + >> str_p(L"<!DOCTYPE") + >> DocTypeDeclChars + >> L'>' + ; + + SignatureAttribute = + str_p(L"signature") + >> Eq + >> L'"' + >> Name [xml::assign_object(rv.class_name)] + >> L'"' + ; + + SerializationWrapper = + !S + >> str_p(L"<boost_serialization") + >> S + >> ( (SignatureAttribute >> S >> VersionAttribute) + | (VersionAttribute >> S >> SignatureAttribute) + ) + >> !S + >> L'>' + ; +} + +template<class CharType> +void basic_xml_grammar<CharType>::init(IStream & is){ + init_chset(); + if(! my_parse(is, XMLDecl)) + boost::serialization::throw_exception( + xml_archive_exception(xml_archive_exception::xml_archive_parsing_error) + ); + if(! my_parse(is, DocTypeDecl)) + boost::serialization::throw_exception( + xml_archive_exception(xml_archive_exception::xml_archive_parsing_error) + ); + if(! my_parse(is, SerializationWrapper)) + boost::serialization::throw_exception( + xml_archive_exception(xml_archive_exception::xml_archive_parsing_error) + ); + if(! std::equal(rv.class_name.begin(), rv.class_name.end(), BOOST_ARCHIVE_SIGNATURE())) + boost::serialization::throw_exception( + archive_exception(archive_exception::invalid_signature) + ); +} + +template<class CharType> +bool basic_xml_grammar<CharType>::windup(IStream & is) { + return my_parse(is, ETag); +} + +} // namespace archive +} // namespace boost diff --git a/src/boost/libs/serialization/src/binary_iarchive.cpp b/src/boost/libs/serialization/src/binary_iarchive.cpp new file mode 100644 index 00000000..41aad841 --- /dev/null +++ b/src/boost/libs/serialization/src/binary_iarchive.cpp @@ -0,0 +1,40 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// binary_iarchive.cpp: + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <istream> + +#define BOOST_ARCHIVE_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/archive/binary_iarchive.hpp> +#include <boost/archive/detail/archive_serializer_map.hpp> + +#include <boost/archive/impl/archive_serializer_map.ipp> +#include <boost/archive/impl/basic_binary_iprimitive.ipp> +#include <boost/archive/impl/basic_binary_iarchive.ipp> + +namespace boost { +namespace archive { + +// explicitly instantiate for this type of stream +template class detail::archive_serializer_map<binary_iarchive>; +template class basic_binary_iprimitive< + binary_iarchive, + std::istream::char_type, + std::istream::traits_type +>; +template class basic_binary_iarchive<binary_iarchive> ; +template class binary_iarchive_impl< + binary_iarchive, + std::istream::char_type, + std::istream::traits_type +>; + +} // namespace archive +} // namespace boost diff --git a/src/boost/libs/serialization/src/binary_oarchive.cpp b/src/boost/libs/serialization/src/binary_oarchive.cpp new file mode 100644 index 00000000..8b86d2cb --- /dev/null +++ b/src/boost/libs/serialization/src/binary_oarchive.cpp @@ -0,0 +1,40 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// binary_oarchive.cpp: + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <ostream> + +#define BOOST_ARCHIVE_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/archive/binary_oarchive.hpp> +#include <boost/archive/detail/archive_serializer_map.hpp> + +// explicitly instantiate for this type of binary stream +#include <boost/archive/impl/archive_serializer_map.ipp> +#include <boost/archive/impl/basic_binary_oprimitive.ipp> +#include <boost/archive/impl/basic_binary_oarchive.ipp> + +namespace boost { +namespace archive { + +template class detail::archive_serializer_map<binary_oarchive>; +template class basic_binary_oprimitive< + binary_oarchive, + std::ostream::char_type, + std::ostream::traits_type +>; +template class basic_binary_oarchive<binary_oarchive> ; +template class binary_oarchive_impl< + binary_oarchive, + std::ostream::char_type, + std::ostream::traits_type +>; + +} // namespace archive +} // namespace boost diff --git a/src/boost/libs/serialization/src/binary_wiarchive.cpp b/src/boost/libs/serialization/src/binary_wiarchive.cpp new file mode 100644 index 00000000..720d469d --- /dev/null +++ b/src/boost/libs/serialization/src/binary_wiarchive.cpp @@ -0,0 +1,47 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// binary_wiarchive.cpp: + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <boost/config.hpp> + +#ifdef BOOST_NO_STD_WSTREAMBUF +#error "wide char i/o not supported on this platform" +#else + +#define BOOST_WARCHIVE_SOURCE +#include <boost/archive/binary_wiarchive.hpp> +#include <boost/archive/detail/archive_serializer_map.hpp> + +// explicitly instantiate for this type of text stream +#include <boost/archive/impl/archive_serializer_map.ipp> +#include <boost/archive/impl/basic_binary_iprimitive.ipp> +#include <boost/archive/impl/basic_binary_iarchive.ipp> + +namespace boost { +namespace archive { + +// explicitly instantiate for this type of text stream +template class detail::archive_serializer_map<binary_wiarchive>; +template class basic_binary_iprimitive< + binary_wiarchive, + wchar_t, + std::char_traits<wchar_t> +>; +template class basic_binary_iarchive<binary_wiarchive> ; +template class binary_iarchive_impl< + binary_wiarchive, + wchar_t, + std::char_traits<wchar_t> +>; + +} // namespace archive +} // namespace boost + +#endif // BOOST_NO_STD_WSTREAMBUF + diff --git a/src/boost/libs/serialization/src/binary_woarchive.cpp b/src/boost/libs/serialization/src/binary_woarchive.cpp new file mode 100644 index 00000000..905a319d --- /dev/null +++ b/src/boost/libs/serialization/src/binary_woarchive.cpp @@ -0,0 +1,44 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// binary_woarchive.cpp: + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <boost/config.hpp> + +#ifdef BOOST_NO_STD_WSTREAMBUF +#error "wide char i/o not supported on this platform" +#else + +#define BOOST_WARCHIVE_SOURCE +#include <boost/archive/binary_woarchive.hpp> + +// explicitly instantiate for this type of text stream +#include <boost/archive/impl/archive_serializer_map.ipp> +#include <boost/archive/impl/basic_binary_oprimitive.ipp> +#include <boost/archive/impl/basic_binary_oarchive.ipp> + +namespace boost { +namespace archive { + +template class detail::archive_serializer_map<binary_woarchive>; +template class basic_binary_oprimitive< + binary_woarchive, + wchar_t, + std::char_traits<wchar_t> +>; +template class basic_binary_oarchive<binary_woarchive> ; +template class binary_oarchive_impl< + binary_woarchive, + wchar_t, + std::char_traits<wchar_t> +>; + +} // namespace archive +} // namespace boost + +#endif // BOOST_NO_STD_WSTREAMBUF diff --git a/src/boost/libs/serialization/src/codecvt_null.cpp b/src/boost/libs/serialization/src/codecvt_null.cpp new file mode 100644 index 00000000..624afc21 --- /dev/null +++ b/src/boost/libs/serialization/src/codecvt_null.cpp @@ -0,0 +1,84 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// codecvt_null.cpp + +// Copyright (c) 2004 Robert Ramey, Indiana University (garcia@osl.iu.edu) +// Andrew Lumsdaine, Indiana University (lums@osl.iu.edu). +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +#define BOOST_WARCHIVE_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/archive/codecvt_null.hpp> + +// codecvt implementation for passing wchar_t objects to char output +// without any translation whatever. Used to implement binary output +// of wchar_t objects. + +namespace boost { +namespace archive { + +std::codecvt_base::result +codecvt_null<wchar_t>::do_out( + std::mbstate_t & /*state*/, + const wchar_t * first1, + const wchar_t * last1, + const wchar_t * & next1, + char * first2, + char * last2, + char * & next2 +) const { + while(first1 != last1){ + // Per std::22.2.1.5.2/2, we can store no more that + // last2-first2 characters. If we need to more encode + // next internal char type, return 'partial'. + if(static_cast<int>(sizeof(wchar_t)) > (last2 - first2)){ + next1 = first1; + next2 = first2; + return std::codecvt_base::partial; + } + * reinterpret_cast<wchar_t *>(first2) = * first1++; + first2 += sizeof(wchar_t); + + } + next1 = first1; + next2 = first2; + return std::codecvt_base::ok; +} + +std::codecvt_base::result +codecvt_null<wchar_t>::do_in( + std::mbstate_t & /*state*/, + const char * first1, + const char * last1, + const char * & next1, + wchar_t * first2, + wchar_t * last2, + wchar_t * & next2 +) const { + // Process input characters until we've run of them, + // or the number of remaining characters is not + // enough to construct another output character, + // or we've run out of place for output characters. + while(first2 != last2){ + // Have we converted all input characters? + // Return with 'ok', if so. + if (first1 == last1) + break; + // Do we have less input characters than needed + // for a single output character? + if(static_cast<int>(sizeof(wchar_t)) > (last1 - first1)){ + next1 = first1; + next2 = first2; + return std::codecvt_base::partial; + } + *first2++ = * reinterpret_cast<const wchar_t *>(first1); + first1 += sizeof(wchar_t); + } + next1 = first1; + next2 = first2; + return std::codecvt_base::ok; +} + +} // namespace archive +} // namespace boost diff --git a/src/boost/libs/serialization/src/extended_type_info.cpp b/src/boost/libs/serialization/src/extended_type_info.cpp new file mode 100644 index 00000000..573336c8 --- /dev/null +++ b/src/boost/libs/serialization/src/extended_type_info.cpp @@ -0,0 +1,196 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// extended_type_info.cpp: implementation for portable version of type_info + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#if (defined _MSC_VER) && (_MSC_VER == 1200) +# pragma warning (disable : 4786) // too long name, harmless warning +#endif + +#include <algorithm> +#include <set> +#include <utility> +#include <boost/assert.hpp> +#include <cstddef> // NULL + +#include <cstring> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ using ::strcmp; } +#endif + +#include <boost/config.hpp> // msvc needs this to suppress warning + +#include <boost/core/no_exceptions_support.hpp> + +// it marks our code with proper attributes as being exported when +// we're compiling it while marking it import when just the headers +// is being included. +#define BOOST_SERIALIZATION_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/serialization/singleton.hpp> +#include <boost/serialization/force_include.hpp> +#include <boost/serialization/extended_type_info.hpp> + +#ifdef BOOST_MSVC +# pragma warning(push) +# pragma warning(disable : 4511 4512) +#endif + +namespace boost { +namespace serialization { +namespace detail { + +struct key_compare +{ + bool + operator()( + const extended_type_info * lhs, + const extended_type_info * rhs + ) const { + // performance shortcut + if(lhs == rhs) + return false; + const char * l = lhs->get_key(); + BOOST_ASSERT(NULL != l); + const char * r = rhs->get_key(); + BOOST_ASSERT(NULL != r); + // performance shortcut + // shortcut to exploit string pooling + if(l == r) + return false; + // for exported types, use the string key so that + // multiple instances in different translation units + // can be matched up + return std::strcmp(l, r) < 0; + } +}; + +typedef std::multiset<const extended_type_info *, key_compare> ktmap; + +#ifdef BOOST_MSVC +# pragma warning(push) +# pragma warning(disable : 4511 4512) +#endif + +class extended_type_info_arg : public extended_type_info +{ + virtual bool + is_less_than(const extended_type_info & /*rhs*/) const { + BOOST_ASSERT(false); + return false; + }; + virtual bool + is_equal(const extended_type_info & /*rhs*/) const { + BOOST_ASSERT(false); + return false; + }; + virtual const char * get_debug_info() const { + return get_key(); + } + virtual void * construct(unsigned int /*count*/, ...) const{ + BOOST_ASSERT(false); + return NULL; + } + virtual void destroy(void const * const /*p*/) const { + BOOST_ASSERT(false); + } +public: + extended_type_info_arg(const char * key) : + extended_type_info(0, key) + {} + + ~extended_type_info_arg(){ + } +}; + +#ifdef BOOST_MSVC +# pragma warning(pop) +#endif + +} // namespace detail + +BOOST_SERIALIZATION_DECL void +extended_type_info::key_register() const{ + if(NULL == get_key()) + return; + singleton<detail::ktmap>::get_mutable_instance().insert(this); +} + +BOOST_SERIALIZATION_DECL void +extended_type_info::key_unregister() const{ + if(NULL == get_key()) + return; + // note: it's been discovered that at least one platform is not guaranteed + // to destroy singletons reverse order of construction. So we can't + // use a runtime assert here. Leave this in a reminder not to do this! + // BOOST_ASSERT(! singleton<detail::ktmap>::is_destroyed()); + if(! singleton<detail::ktmap>::is_destroyed()){ + detail::ktmap & x = singleton<detail::ktmap>::get_mutable_instance(); + detail::ktmap::iterator start = x.lower_bound(this); + detail::ktmap::iterator end = x.upper_bound(this); + // remove entry in map which corresponds to this type + for(;start != end; ++start){ + if(this == *start){ + x.erase(start); + break; + } + } + } +} + +BOOST_SERIALIZATION_DECL const extended_type_info * +extended_type_info::find(const char *key) { + BOOST_ASSERT(NULL != key); + const detail::ktmap & k = singleton<detail::ktmap>::get_const_instance(); + const detail::extended_type_info_arg eti_key(key); + const detail::ktmap::const_iterator it = k.find(& eti_key); + if(k.end() == it) + return NULL; + return *(it); +} + +BOOST_SERIALIZATION_DECL +extended_type_info::extended_type_info( + const unsigned int type_info_key, + const char * key +) : + m_type_info_key(type_info_key), + m_key(key) +{ +} + +BOOST_SERIALIZATION_DECL +extended_type_info::~extended_type_info(){ +} + +BOOST_SERIALIZATION_DECL bool +extended_type_info::operator<(const extended_type_info &rhs) const { + // short cut for a common cases + if(this == & rhs) + return false; + if(m_type_info_key == rhs.m_type_info_key){ + return is_less_than(rhs); + } + if(m_type_info_key < rhs.m_type_info_key) + return true; + return false; +} + +BOOST_SERIALIZATION_DECL bool +extended_type_info::operator==(const extended_type_info &rhs) const { + // short cut for a common cases + if(this == & rhs) + return true; + if(m_type_info_key != rhs.m_type_info_key){ + return false; + } + return is_equal(rhs); +} + +} // namespace serialization +} // namespace boost diff --git a/src/boost/libs/serialization/src/extended_type_info_no_rtti.cpp b/src/boost/libs/serialization/src/extended_type_info_no_rtti.cpp new file mode 100644 index 00000000..0a8d2a07 --- /dev/null +++ b/src/boost/libs/serialization/src/extended_type_info_no_rtti.cpp @@ -0,0 +1,89 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// extended_type_info_no_rtti.cpp: specific implementation of type info +// that is NOT based on typeid + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <cstring> +#include <cstddef> // NULL +#include <boost/assert.hpp> + +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ using ::strcmp; } +#endif + +// it marks our code with proper attributes as being exported when +// we're compiling it while marking it import when just the headers +// is being included. +#define BOOST_SERIALIZATION_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/serialization/extended_type_info_no_rtti.hpp> + +#define EXTENDED_TYPE_INFO_NO_RTTI_KEY 2 + +namespace boost { +namespace serialization { +namespace no_rtti_system { + +BOOST_SERIALIZATION_DECL +extended_type_info_no_rtti_0::extended_type_info_no_rtti_0( + const char * key +) : + extended_type_info(EXTENDED_TYPE_INFO_NO_RTTI_KEY, key) +{} + +BOOST_SERIALIZATION_DECL bool +extended_type_info_no_rtti_0::is_less_than( + const boost::serialization::extended_type_info &rhs) const +{ + // shortcut for common case + if(this == & rhs) + return false; + const char * l = get_key(); + const char * r = rhs.get_key(); + // if this assertion is triggered, it could mean one of the following + // a) This class was never exported - make sure all calls which use + // this method of type id are in fact exported. + // b) This class was used (e.g. serialized through a pointer) before + // it was exported. Make sure that classes which use this method + // of type id are NOT "automatically" registered by serializating + // through a pointer to the to most derived class. OR make sure + // that the BOOST_CLASS_EXPORT is included in every file + // which does this. + BOOST_ASSERT(NULL != l); + BOOST_ASSERT(NULL != r); + return std::strcmp(l, r) < 0; +} + +BOOST_SERIALIZATION_DECL bool +extended_type_info_no_rtti_0::is_equal( + const boost::serialization::extended_type_info &rhs) const +{ + // shortcut for common case + if(this == & rhs) + return true; + // null keys don't match with anything + const char * l = get_key(); + BOOST_ASSERT(NULL != l); + if(NULL == l) + return false; + const char * r = rhs.get_key(); + BOOST_ASSERT(NULL != r); + if(NULL == r) + return false; + return 0 == std::strcmp(l, r); +} + +BOOST_SERIALIZATION_DECL +extended_type_info_no_rtti_0::~extended_type_info_no_rtti_0() +{} + +} // namespece detail +} // namespace serialization +} // namespace boost diff --git a/src/boost/libs/serialization/src/extended_type_info_typeid.cpp b/src/boost/libs/serialization/src/extended_type_info_typeid.cpp new file mode 100644 index 00000000..91ace4c3 --- /dev/null +++ b/src/boost/libs/serialization/src/extended_type_info_typeid.cpp @@ -0,0 +1,167 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// extended_type_info_typeid.cpp: specific implementation of type info +// that is based on typeid + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <algorithm> +#include <set> +#include <boost/assert.hpp> +#include <typeinfo> +#include <cstddef> // NULL + +#include <boost/core/no_exceptions_support.hpp> + +// it marks our code with proper attributes as being exported when +// we're compiling it while marking it import when just the headers +// is being included. +#define BOOST_SERIALIZATION_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/serialization/singleton.hpp> +#include <boost/serialization/extended_type_info_typeid.hpp> + +namespace boost { +namespace serialization { +namespace typeid_system { + +#define EXTENDED_TYPE_INFO_TYPE_KEY 1 + +struct type_compare +{ + bool + operator()( + const extended_type_info_typeid_0 * lhs, + const extended_type_info_typeid_0 * rhs + ) const { + return lhs->is_less_than(*rhs); + } +}; + +typedef std::multiset< + const extended_type_info_typeid_0 *, + type_compare +> tkmap; + +BOOST_SERIALIZATION_DECL bool +extended_type_info_typeid_0::is_less_than( + const boost::serialization::extended_type_info & rhs +) const { + // shortcut for common case + if(this == & rhs) + return false; + return 0 != m_ti->before( + *(static_cast<const extended_type_info_typeid_0 &>(rhs).m_ti) + ); +} + +BOOST_SERIALIZATION_DECL bool +extended_type_info_typeid_0::is_equal( + const boost::serialization::extended_type_info & rhs +) const { + return + // note: std::type_info == operator returns an int !!! + // the following permits conversion to bool without a warning. + ! ( + * m_ti + != *(static_cast<const extended_type_info_typeid_0 &>(rhs).m_ti) + ) + ; +} + +BOOST_SERIALIZATION_DECL +extended_type_info_typeid_0::extended_type_info_typeid_0( + const char * key +) : + extended_type_info(EXTENDED_TYPE_INFO_TYPE_KEY, key), + m_ti(NULL) +{} + +BOOST_SERIALIZATION_DECL +extended_type_info_typeid_0::~extended_type_info_typeid_0() +{} + +BOOST_SERIALIZATION_DECL void +extended_type_info_typeid_0::type_register(const std::type_info & ti){ + m_ti = & ti; + singleton<tkmap>::get_mutable_instance().insert(this); +} + +BOOST_SERIALIZATION_DECL void +extended_type_info_typeid_0::type_unregister() +{ + if(NULL != m_ti){ + // note: previously this conditional was a runtime assertion with + // BOOST_ASSERT. We've changed it because we've discovered that at + // least one platform is not guaranteed to destroy singletons in + // reverse order of distruction. + // BOOST_ASSERT(! singleton<tkmap>::is_destroyed()); + if(! singleton<tkmap>::is_destroyed()){ + tkmap & x = singleton<tkmap>::get_mutable_instance(); + + // remove all entries in map which corresponds to this type + // make sure that we don't use any invalidated iterators + for(;;){ + const tkmap::iterator & it = x.find(this); + if(it == x.end()) + break; + x.erase(it); + }; + } + } + m_ti = NULL; +} + +#ifdef BOOST_MSVC +# pragma warning(push) +# pragma warning(disable : 4511 4512) +#endif + +// this derivation is used for creating search arguments +class extended_type_info_typeid_arg : + public extended_type_info_typeid_0 +{ + virtual void * construct(unsigned int /*count*/, ...) const{ + BOOST_ASSERT(false); + return NULL; + } + virtual void destroy(void const * const /*p*/) const { + BOOST_ASSERT(false); + } +public: + extended_type_info_typeid_arg(const std::type_info & ti) : + extended_type_info_typeid_0(NULL) + { + // note absense of self register and key as this is used only as + // search argument given a type_info reference and is not to + // be added to the map. + m_ti = & ti; + } + ~extended_type_info_typeid_arg(){ + m_ti = NULL; + } +}; + +#ifdef BOOST_MSVC +# pragma warning(pop) +#endif + +BOOST_SERIALIZATION_DECL const extended_type_info * +extended_type_info_typeid_0::get_extended_type_info( + const std::type_info & ti +) const { + typeid_system::extended_type_info_typeid_arg etia(ti); + const tkmap & t = singleton<tkmap>::get_const_instance(); + const tkmap::const_iterator it = t.find(& etia); + if(t.end() == it) + return NULL; + return *(it); +} + +} // namespace detail +} // namespace serialization +} // namespace boost diff --git a/src/boost/libs/serialization/src/polymorphic_binary_iarchive.cpp b/src/boost/libs/serialization/src/polymorphic_binary_iarchive.cpp new file mode 100644 index 00000000..7fcca705 --- /dev/null +++ b/src/boost/libs/serialization/src/polymorphic_binary_iarchive.cpp @@ -0,0 +1,30 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// polymorphic_binary_iarchive.cpp: + +// (C) Copyright 2018 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#if (defined _MSC_VER) && (_MSC_VER == 1200) +# pragma warning (disable : 4786) // too long name, harmless warning +#endif + +#define BOOST_ARCHIVE_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/archive/polymorphic_binary_iarchive.hpp> + +// explicitly instantiate for this type of text stream +#include <boost/archive/impl/archive_serializer_map.ipp> + +namespace boost { +namespace archive { +namespace detail { + +template class archive_serializer_map<polymorphic_binary_iarchive>; + +} // detail +} // archive +} // boost diff --git a/src/boost/libs/serialization/src/polymorphic_binary_oarchive.cpp b/src/boost/libs/serialization/src/polymorphic_binary_oarchive.cpp new file mode 100644 index 00000000..8b66c5cb --- /dev/null +++ b/src/boost/libs/serialization/src/polymorphic_binary_oarchive.cpp @@ -0,0 +1,30 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// polymorphic_binary_oarchive.cpp: + +// (C) Copyright 2018 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#if (defined _MSC_VER) && (_MSC_VER == 1200) +# pragma warning (disable : 4786) // too long name, harmless warning +#endif + +#define BOOST_ARCHIVE_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/archive/polymorphic_binary_oarchive.hpp> + +// explicitly instantiate for this type of text stream +#include <boost/archive/impl/archive_serializer_map.ipp> + +namespace boost { +namespace archive { +namespace detail { + +template class detail::archive_serializer_map<polymorphic_binary_oarchive>; + +} // detail +} // archive +} // boost diff --git a/src/boost/libs/serialization/src/polymorphic_iarchive.cpp b/src/boost/libs/serialization/src/polymorphic_iarchive.cpp new file mode 100644 index 00000000..249363b8 --- /dev/null +++ b/src/boost/libs/serialization/src/polymorphic_iarchive.cpp @@ -0,0 +1,30 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// polymorphic_iarchive.cpp: + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#if (defined _MSC_VER) && (_MSC_VER == 1200) +# pragma warning (disable : 4786) // too long name, harmless warning +#endif + +#define BOOST_ARCHIVE_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/archive/detail/archive_serializer_map.hpp> + +#include <boost/archive/impl/archive_serializer_map.ipp> +#include <boost/archive/polymorphic_iarchive.hpp> + +namespace boost { +namespace archive { +namespace detail { + +template class archive_serializer_map<polymorphic_iarchive>; + +} // detail +} // archive +} // boost diff --git a/src/boost/libs/serialization/src/polymorphic_oarchive.cpp b/src/boost/libs/serialization/src/polymorphic_oarchive.cpp new file mode 100644 index 00000000..f63296be --- /dev/null +++ b/src/boost/libs/serialization/src/polymorphic_oarchive.cpp @@ -0,0 +1,30 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// polymorphic_oarchive.cpp: + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#if (defined _MSC_VER) && (_MSC_VER == 1200) +# pragma warning (disable : 4786) // too long name, harmless warning +#endif + +#define BOOST_ARCHIVE_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/archive/detail/archive_serializer_map.hpp> + +#include <boost/archive/impl/archive_serializer_map.ipp> +#include <boost/archive/polymorphic_oarchive.hpp> + +namespace boost { +namespace archive { +namespace detail { + +template class archive_serializer_map<polymorphic_oarchive>; + +} // detail +} // archive +} // boost diff --git a/src/boost/libs/serialization/src/polymorphic_text_iarchive.cpp b/src/boost/libs/serialization/src/polymorphic_text_iarchive.cpp new file mode 100644 index 00000000..6404ec83 --- /dev/null +++ b/src/boost/libs/serialization/src/polymorphic_text_iarchive.cpp @@ -0,0 +1,30 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// polymorphic_text_iarchive.cpp: + +// (C) Copyright 2018 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#if (defined _MSC_VER) && (_MSC_VER == 1200) +# pragma warning (disable : 4786) // too long name, harmless warning +#endif + +#define BOOST_ARCHIVE_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/archive/polymorphic_text_iarchive.hpp> + +// explicitly instantiate for this type of text stream +#include <boost/archive/impl/archive_serializer_map.ipp> + +namespace boost { +namespace archive { +namespace detail { + +template class archive_serializer_map<polymorphic_text_iarchive>; + +} // detail +} // archive +} // boost diff --git a/src/boost/libs/serialization/src/polymorphic_text_oarchive.cpp b/src/boost/libs/serialization/src/polymorphic_text_oarchive.cpp new file mode 100644 index 00000000..4160a621 --- /dev/null +++ b/src/boost/libs/serialization/src/polymorphic_text_oarchive.cpp @@ -0,0 +1,30 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// polymorphic_text_oarchive.cpp: + +// (C) Copyright 2018 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#if (defined _MSC_VER) && (_MSC_VER == 1200) +# pragma warning (disable : 4786) // too long name, harmless warning +#endif + +#define BOOST_ARCHIVE_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/archive/polymorphic_text_oarchive.hpp> + +// explicitly instantiate for this type of text stream +#include <boost/archive/impl/archive_serializer_map.ipp> + +namespace boost { +namespace archive { +namespace detail { + +template class detail::archive_serializer_map<polymorphic_text_oarchive>; + +} // detail +} // archive +} // boost diff --git a/src/boost/libs/serialization/src/polymorphic_text_wiarchive.cpp b/src/boost/libs/serialization/src/polymorphic_text_wiarchive.cpp new file mode 100644 index 00000000..2089195a --- /dev/null +++ b/src/boost/libs/serialization/src/polymorphic_text_wiarchive.cpp @@ -0,0 +1,30 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// polymorphic_text_wiarchive.cpp: + +// (C) Copyright 2018 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#if (defined _MSC_VER) && (_MSC_VER == 1200) +# pragma warning (disable : 4786) // too long name, harmless warning +#endif + +#define BOOST_ARCHIVE_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/archive/polymorphic_text_wiarchive.hpp> + +// explicitly instantiate for this type of text stream +#include <boost/archive/impl/archive_serializer_map.ipp> + +namespace boost { +namespace archive { +namespace detail { + +template class archive_serializer_map<polymorphic_text_wiarchive>; + +} // detail +} // archive +} // boost diff --git a/src/boost/libs/serialization/src/polymorphic_text_woarchive.cpp b/src/boost/libs/serialization/src/polymorphic_text_woarchive.cpp new file mode 100644 index 00000000..514f1447 --- /dev/null +++ b/src/boost/libs/serialization/src/polymorphic_text_woarchive.cpp @@ -0,0 +1,30 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// polymorphic_text_woarchive.cpp: + +// (C) Copyright 2018 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#if (defined _MSC_VER) && (_MSC_VER == 1200) +# pragma warning (disable : 4786) // too long name, harmless warning +#endif + +#define BOOST_ARCHIVE_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/archive/polymorphic_text_woarchive.hpp> + +// explicitly instantiate for this type of text stream +#include <boost/archive/impl/archive_serializer_map.ipp> + +namespace boost { +namespace archive { +namespace detail { + +template class detail::archive_serializer_map<polymorphic_text_woarchive>; + +} // detail +} // archive +} // boost diff --git a/src/boost/libs/serialization/src/polymorphic_xml_iarchive.cpp b/src/boost/libs/serialization/src/polymorphic_xml_iarchive.cpp new file mode 100644 index 00000000..17ec7917 --- /dev/null +++ b/src/boost/libs/serialization/src/polymorphic_xml_iarchive.cpp @@ -0,0 +1,30 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// polymorphic_xml_iarchive.cpp: + +// (C) Copyright 2018 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#if (defined _MSC_VER) && (_MSC_VER == 1200) +# pragma warning (disable : 4786) // too long name, harmless warning +#endif + +#define BOOST_ARCHIVE_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/archive/polymorphic_xml_iarchive.hpp> + +// explicitly instantiate for this type of text stream +#include <boost/archive/impl/archive_serializer_map.ipp> + +namespace boost { +namespace archive { +namespace detail { + +template class archive_serializer_map<polymorphic_xml_iarchive>; + +} // detail +} // archive +} // boost diff --git a/src/boost/libs/serialization/src/polymorphic_xml_oarchive.cpp b/src/boost/libs/serialization/src/polymorphic_xml_oarchive.cpp new file mode 100644 index 00000000..124f899f --- /dev/null +++ b/src/boost/libs/serialization/src/polymorphic_xml_oarchive.cpp @@ -0,0 +1,30 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// polymorphic_xml_oarchive.cpp: + +// (C) Copyright 2018 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#if (defined _MSC_VER) && (_MSC_VER == 1200) +# pragma warning (disable : 4786) // too long name, harmless warning +#endif + +#define BOOST_ARCHIVE_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/archive/polymorphic_xml_oarchive.hpp> + +// explicitly instantiate for this type of text stream +#include <boost/archive/impl/archive_serializer_map.ipp> + +namespace boost { +namespace archive { +namespace detail { + +template class detail::archive_serializer_map<polymorphic_xml_oarchive>; + +} // detail +} // archive +} // boost diff --git a/src/boost/libs/serialization/src/polymorphic_xml_wiarchive.cpp b/src/boost/libs/serialization/src/polymorphic_xml_wiarchive.cpp new file mode 100644 index 00000000..1548c9ed --- /dev/null +++ b/src/boost/libs/serialization/src/polymorphic_xml_wiarchive.cpp @@ -0,0 +1,30 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// polymorphic_xml_wiarchive.cpp: + +// (C) Copyright 2018 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#if (defined _MSC_VER) && (_MSC_VER == 1200) +# pragma warning (disable : 4786) // too long name, harmless warning +#endif + +#define BOOST_ARCHIVE_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/archive/polymorphic_xml_wiarchive.hpp> + +// explicitly instantiate for this type of text stream +#include <boost/archive/impl/archive_serializer_map.ipp> + +namespace boost { +namespace archive { +namespace detail { + +template class archive_serializer_map<polymorphic_xml_wiarchive>; + +} // detail +} // archive +} // boost diff --git a/src/boost/libs/serialization/src/polymorphic_xml_woarchive.cpp b/src/boost/libs/serialization/src/polymorphic_xml_woarchive.cpp new file mode 100644 index 00000000..47989456 --- /dev/null +++ b/src/boost/libs/serialization/src/polymorphic_xml_woarchive.cpp @@ -0,0 +1,30 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// polymorphic_xml_woarchive.cpp: + +// (C) Copyright 2018 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#if (defined _MSC_VER) && (_MSC_VER == 1200) +# pragma warning (disable : 4786) // too long name, harmless warning +#endif + +#define BOOST_ARCHIVE_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/archive/polymorphic_xml_woarchive.hpp> + +// explicitly instantiate for this type of text stream +#include <boost/archive/impl/archive_serializer_map.ipp> + +namespace boost { +namespace archive { +namespace detail { + +template class detail::archive_serializer_map<polymorphic_xml_woarchive>; + +} // detail +} // archive +} // boost diff --git a/src/boost/libs/serialization/src/stl_port.cpp b/src/boost/libs/serialization/src/stl_port.cpp new file mode 100644 index 00000000..343faa6d --- /dev/null +++ b/src/boost/libs/serialization/src/stl_port.cpp @@ -0,0 +1,42 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// stl_port.cpp: implementation of run-time casting of void pointers + +// (C) Copyright 2005 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#if (defined _MSC_VER) && (_MSC_VER == 1200) +# pragma warning (disable : 4786) // too long name, harmless warning +#endif + +// this befuddles the msvc 6 compiler so we can't use it +#if ! ((defined _MSC_VER) && (_MSC_VER <= 1300)) + +#include <boost/config.hpp> + +#if defined(__SGI_STL_PORT) && (__SGI_STL_PORT < 0x500) + +#include <boost/archive/codecvt_null.hpp> + +// explicit instantiation + +namespace std { + +template +locale::locale( + const locale& __loc, boost::archive::codecvt_null<char> * __f +); + +template +locale::locale( + const locale& __loc, boost::archive::codecvt_null<wchar_t> * __f +); + +} // namespace std + +#endif + +#endif diff --git a/src/boost/libs/serialization/src/text_iarchive.cpp b/src/boost/libs/serialization/src/text_iarchive.cpp new file mode 100644 index 00000000..dfcff4e1 --- /dev/null +++ b/src/boost/libs/serialization/src/text_iarchive.cpp @@ -0,0 +1,33 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// text_iarchive.cpp: + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#if (defined _MSC_VER) && (_MSC_VER == 1200) +# pragma warning (disable : 4786) // too long name, harmless warning +#endif + +#define BOOST_ARCHIVE_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/archive/text_iarchive.hpp> +#include <boost/archive/detail/archive_serializer_map.hpp> + +// explicitly instantiate for this type of text stream +#include <boost/archive/impl/archive_serializer_map.ipp> +#include <boost/archive/impl/basic_text_iarchive.ipp> +#include <boost/archive/impl/text_iarchive_impl.ipp> + +namespace boost { +namespace archive { + +template class detail::archive_serializer_map<text_iarchive>; +template class basic_text_iarchive<text_iarchive> ; +template class text_iarchive_impl<text_iarchive> ; + +} // namespace archive +} // namespace boost diff --git a/src/boost/libs/serialization/src/text_oarchive.cpp b/src/boost/libs/serialization/src/text_oarchive.cpp new file mode 100644 index 00000000..ae24a0bf --- /dev/null +++ b/src/boost/libs/serialization/src/text_oarchive.cpp @@ -0,0 +1,34 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// text_oarchive.cpp: + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#if (defined _MSC_VER) && (_MSC_VER == 1200) +# pragma warning (disable : 4786) // too long name, harmless warning +#endif + +#define BOOST_ARCHIVE_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/archive/text_oarchive.hpp> +#include <boost/archive/detail/archive_serializer_map.hpp> + +// explicitly instantiate for this type of text stream +#include <boost/archive/impl/archive_serializer_map.ipp> +#include <boost/archive/impl/basic_text_oarchive.ipp> +#include <boost/archive/impl/text_oarchive_impl.ipp> + +namespace boost { +namespace archive { + +//template class basic_text_oprimitive<std::ostream> ; +template class detail::archive_serializer_map<text_oarchive>; +template class basic_text_oarchive<text_oarchive> ; +template class text_oarchive_impl<text_oarchive> ; + +} // namespace serialization +} // namespace boost diff --git a/src/boost/libs/serialization/src/text_wiarchive.cpp b/src/boost/libs/serialization/src/text_wiarchive.cpp new file mode 100644 index 00000000..6b6e592f --- /dev/null +++ b/src/boost/libs/serialization/src/text_wiarchive.cpp @@ -0,0 +1,38 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// text_wiarchive.cpp: + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <boost/config.hpp> + +#ifdef BOOST_NO_STD_WSTREAMBUF +#error "wide char i/o not supported on this platform" +#else + +#define BOOST_WARCHIVE_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/archive/text_wiarchive.hpp> +#include <boost/archive/detail/archive_serializer_map.hpp> + +// explicitly instantiate for this type of text stream +#include <boost/archive/impl/archive_serializer_map.ipp> +#include <boost/archive/impl/basic_text_iarchive.ipp> +#include <boost/archive/impl/text_wiarchive_impl.ipp> + +namespace boost { +namespace archive { + +template class detail::archive_serializer_map<text_wiarchive>; +template class basic_text_iarchive<text_wiarchive> ; +template class text_wiarchive_impl<text_wiarchive> ; + +} // namespace archive +} // namespace boost + +#endif // BOOST_NO_STD_WSTREAMBUF + diff --git a/src/boost/libs/serialization/src/text_woarchive.cpp b/src/boost/libs/serialization/src/text_woarchive.cpp new file mode 100644 index 00000000..46441694 --- /dev/null +++ b/src/boost/libs/serialization/src/text_woarchive.cpp @@ -0,0 +1,36 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// text_woarchive.cpp: + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <boost/config.hpp> +#ifdef BOOST_NO_STD_WSTREAMBUF +#error "wide char i/o not supported on this platform" +#else + +#define BOOST_WARCHIVE_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/archive/text_woarchive.hpp> +#include <boost/archive/detail/archive_serializer_map.hpp> + +// explicitly instantiate for this type of text stream +#include <boost/archive/impl/archive_serializer_map.ipp> +#include <boost/archive/impl/basic_text_oarchive.ipp> +#include <boost/archive/impl/text_woarchive_impl.ipp> + +namespace boost { +namespace archive { + +template class detail::archive_serializer_map<text_woarchive>; +template class basic_text_oarchive<text_woarchive> ; +template class text_woarchive_impl<text_woarchive> ; + +} // namespace archive +} // namespace boost + +#endif // BOOST_NO_STD_WSTREAMBUF diff --git a/src/boost/libs/serialization/src/utf8_codecvt_facet.cpp b/src/boost/libs/serialization/src/utf8_codecvt_facet.cpp new file mode 100644 index 00000000..f6550d07 --- /dev/null +++ b/src/boost/libs/serialization/src/utf8_codecvt_facet.cpp @@ -0,0 +1,22 @@ +// Copyright Vladimir Prus 2004. +// Distributed under the Boost Software License, Version 1.0. +// (See accompanying file LICENSE_1_0.txt +// or copy at http://www.boost.org/LICENSE_1_0.txt) + +#include <boost/config.hpp> + +#ifdef BOOST_NO_STD_WSTREAMBUF +#error "wide char i/o not supported on this platform" +#endif + +// include boost implementation of utf8 codecvt facet +# define BOOST_ARCHIVE_SOURCE +#include <boost/archive/detail/decl.hpp> +#define BOOST_UTF8_BEGIN_NAMESPACE \ + namespace boost { namespace archive { namespace detail { +#define BOOST_UTF8_DECL BOOST_ARCHIVE_DECL +#define BOOST_UTF8_END_NAMESPACE }}} +#include <boost/detail/utf8_codecvt_facet.ipp> +#undef BOOST_UTF8_END_NAMESPACE +#undef BOOST_UTF8_DECL +#undef BOOST_UTF8_BEGIN_NAMESPACE diff --git a/src/boost/libs/serialization/src/void_cast.cpp b/src/boost/libs/serialization/src/void_cast.cpp new file mode 100644 index 00000000..535988f8 --- /dev/null +++ b/src/boost/libs/serialization/src/void_cast.cpp @@ -0,0 +1,382 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// void_cast.cpp: implementation of run-time casting of void pointers + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) +// <gennadiy.rozental@tfn.com> + +// See http://www.boost.org for updates, documentation, and revision history. + +#if (defined _MSC_VER) && (_MSC_VER == 1200) +# pragma warning (disable : 4786) // too long name, harmless warning +#endif + +// STL +#include <set> +#include <functional> +#include <algorithm> +#include <cstddef> // NULL +#ifdef BOOST_SERIALIZATION_LOG +#include <iostream> +#endif + +// BOOST +#include <boost/config.hpp> +#include <boost/assert.hpp> + +#define BOOST_SERIALIZATION_SOURCE +#include <boost/serialization/config.hpp> +// it marks our code with proper attributes as being exported when +// we're compiling it while marking it import when just the headers +// is being included. +#include <boost/serialization/singleton.hpp> +#include <boost/serialization/extended_type_info.hpp> +#include <boost/serialization/void_cast.hpp> + +namespace boost { +namespace serialization { +namespace void_cast_detail { + +// note that void_casters are keyed on value of +// member extended type info records - NOT their +// addresses. This is necessary in order for the +// void cast operations to work across dll and exe +// module boundries. +bool void_caster::operator<(const void_caster & rhs) const { + // include short cut to save time and eliminate + // problems when when base class aren't virtual + if(m_derived != rhs.m_derived){ + if(*m_derived < *rhs.m_derived) + return true; + if(*rhs.m_derived < *m_derived) + return false; + } + // m_derived == rhs.m_derived + if(m_base != rhs.m_base) + return *m_base < *rhs.m_base; + else + return false; +} + +struct void_caster_compare { + bool operator()(const void_caster * lhs, const void_caster * rhs) const { + return *lhs < *rhs; + } +}; + +typedef std::set<const void_caster *, void_caster_compare> set_type; +typedef boost::serialization::singleton<set_type> void_caster_registry; + +#ifdef BOOST_MSVC +# pragma warning(push) +# pragma warning(disable : 4511 4512) +#endif + +// implementation of shortcut void caster +class void_caster_shortcut : public void_caster +{ + bool m_includes_virtual_base; + + void const * + vbc_upcast( + void const * const t + ) const; + void const * + vbc_downcast( + void const * const t + ) const; + virtual void const * + upcast(void const * const t) const{ + if(m_includes_virtual_base) + return vbc_upcast(t); + return static_cast<const char *> ( t ) - m_difference; + } + virtual void const * + downcast(void const * const t) const{ + if(m_includes_virtual_base) + return vbc_downcast(t); + return static_cast<const char *> ( t ) + m_difference; + } + virtual bool is_shortcut() const { + return true; + } + virtual bool has_virtual_base() const { + return m_includes_virtual_base; + } +public: + void_caster_shortcut( + extended_type_info const * derived, + extended_type_info const * base, + std::ptrdiff_t difference, + bool includes_virtual_base, + void_caster const * const parent + ) : + void_caster(derived, base, difference, parent), + m_includes_virtual_base(includes_virtual_base) + { + recursive_register(includes_virtual_base); + } + virtual ~void_caster_shortcut(){ + recursive_unregister(); + } +}; + +#ifdef BOOST_MSVC +# pragma warning(pop) +#endif + +void const * +void_caster_shortcut::vbc_downcast( + void const * const t +) const { + // try to find a chain that gives us what we want + const void_cast_detail::set_type & s + = void_cast_detail::void_caster_registry::get_const_instance(); + void_cast_detail::set_type::const_iterator it; + for(it = s.begin(); it != s.end(); ++it){ + // if the current candidate casts to the desired target type + if ((*it)->m_derived == m_derived){ + // and if it's not us + if ((*it)->m_base != m_base){ + // try to cast from the candidate base to our base + const void * t_new; + t_new = void_downcast(*(*it)->m_base, *m_base, t); + // if we were successful + if(NULL != t_new){ + // recast to our derived + const void_caster * vc = *it; + return vc->downcast(t_new); + } + } + } + } + return NULL; +} + +void const * +void_caster_shortcut::vbc_upcast( + void const * const t +) const { + // try to find a chain that gives us what we want + const void_cast_detail::set_type & s + = void_cast_detail::void_caster_registry::get_const_instance(); + void_cast_detail::set_type::const_iterator it; + for(it = s.begin(); it != s.end(); ++it){ + // if the current candidate casts from the desired base type + if((*it)->m_base == m_base){ + // and if it's not us + if ((*it)->m_derived != m_derived){ + // try to cast from the candidate derived to our our derived + const void * t_new; + t_new = void_upcast(*m_derived, *(*it)->m_derived, t); + if(NULL != t_new) + return (*it)->upcast(t_new); + } + } + } + return NULL; +} + +#ifdef BOOST_MSVC +# pragma warning(push) +# pragma warning(disable : 4511 4512) +#endif + +// just used as a search key +class void_caster_argument : public void_caster +{ + virtual void const * + upcast(void const * const /*t*/) const { + BOOST_ASSERT(false); + return NULL; + } + virtual void const * + downcast( void const * const /*t*/) const { + BOOST_ASSERT(false); + return NULL; + } + virtual bool has_virtual_base() const { + BOOST_ASSERT(false); + return false; + } +public: + void_caster_argument( + extended_type_info const * derived, + extended_type_info const * base + ) : + void_caster(derived, base) + {} + virtual ~void_caster_argument(){}; +}; + +#ifdef BOOST_MSVC +# pragma warning(pop) +#endif + +// implementation of void caster base class +BOOST_SERIALIZATION_DECL void +void_caster::recursive_register(bool includes_virtual_base) const { + void_cast_detail::set_type & s + = void_cast_detail::void_caster_registry::get_mutable_instance(); + + #ifdef BOOST_SERIALIZATION_LOG + std::clog << "recursive_register\n"; + std::clog << m_derived->get_debug_info(); + std::clog << "<-"; + std::clog << m_base->get_debug_info(); + std::clog << "\n"; + #endif + + std::pair<void_cast_detail::set_type::const_iterator, bool> result; + // comment this out for now. + result = s.insert(this); + //assert(result.second); + + // generate all implied void_casts. + void_cast_detail::set_type::const_iterator it; + for(it = s.begin(); it != s.end(); ++it){ + if(* m_derived == * (*it)->m_base){ + const void_caster_argument vca( + (*it)->m_derived, + m_base + ); + void_cast_detail::set_type::const_iterator i; + i = s.find(& vca); + if(i == s.end()){ + new void_caster_shortcut( + (*it)->m_derived, + m_base, + m_difference + (*it)->m_difference, + (*it)->has_virtual_base() || includes_virtual_base, + this + ); + } + } + if(* (*it)->m_derived == * m_base){ + const void_caster_argument vca( + m_derived, + (*it)->m_base + ); + void_cast_detail::set_type::const_iterator i; + i = s.find(& vca); + if(i == s.end()){ + new void_caster_shortcut( + m_derived, + (*it)->m_base, + m_difference + (*it)->m_difference, + (*it)->has_virtual_base() || includes_virtual_base, + this + ); + } + } + } +} + +BOOST_SERIALIZATION_DECL void +void_caster::recursive_unregister() const { + // note: it's been discovered that at least one platform is not guaranteed + // to destroy singletons reverse order of construction. So we can't + // use a runtime assert here. Leave this in a reminder not to do this! + // BOOST_ASSERT(! void_caster_registry::is_destroyed()); + if(void_caster_registry::is_destroyed()) + return; + + #ifdef BOOST_SERIALIZATION_LOG + std::clog << "recursive_unregister\n"; + std::clog << m_derived->get_debug_info(); + std::clog << "<-"; + std::clog << m_base->get_debug_info(); + std::clog << "\n"; + #endif + + void_cast_detail::set_type & s + = void_caster_registry::get_mutable_instance(); + + // delete all shortcuts which use this primitive + void_cast_detail::set_type::iterator it; + for(it = s.begin(); it != s.end();){ + const void_caster * vc = *it; + if(vc == this){ + s.erase(it++); + } + else + if(vc->m_parent == this){ + s.erase(it); + delete vc; + it = s.begin(); + } + else + it++; + } +} + +} // namespace void_cast_detail + +BOOST_SYMBOL_VISIBLE void const * +void_upcast( + extended_type_info const & derived, + extended_type_info const & base, + void const * const t +); + +// Given a void *, assume that it really points to an instance of one type +// and alter it so that it would point to an instance of a related type. +// Return the altered pointer. If there exists no sequence of casts that +// can transform from_type to to_type, return a NULL. +BOOST_SERIALIZATION_DECL void const * +void_upcast( + extended_type_info const & derived, + extended_type_info const & base, + void const * const t +){ + // same types - trivial case + if (derived == base) + return t; + + // check to see if base/derived pair is found in the registry + const void_cast_detail::set_type & s + = void_cast_detail::void_caster_registry::get_const_instance(); + const void_cast_detail::void_caster_argument ca(& derived, & base); + + void_cast_detail::set_type::const_iterator it; + it = s.find(& ca); + if (s.end() != it) + return (*it)->upcast(t); + + return NULL; +} + +BOOST_SYMBOL_VISIBLE void const * +void_downcast( + extended_type_info const & derived, + extended_type_info const & base, + void const * const t +); + +BOOST_SERIALIZATION_DECL void const * +void_downcast( + extended_type_info const & derived, + extended_type_info const & base, + void const * const t +){ + // same types - trivial case + if (derived == base) + return t; + + // check to see if base/derived pair is found in the registry + const void_cast_detail::set_type & s + = void_cast_detail::void_caster_registry::get_const_instance(); + const void_cast_detail::void_caster_argument ca(& derived, & base); + + void_cast_detail::set_type::const_iterator it; + it = s.find(&ca); + if (s.end() != it) + return(*it)->downcast(t); + + return NULL; +} + +} // namespace serialization +} // namespace boost diff --git a/src/boost/libs/serialization/src/xml_archive_exception.cpp b/src/boost/libs/serialization/src/xml_archive_exception.cpp new file mode 100644 index 00000000..f4ca98c0 --- /dev/null +++ b/src/boost/libs/serialization/src/xml_archive_exception.cpp @@ -0,0 +1,68 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// xml_archive_exception.cpp: + +// (C) Copyright 2009 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#if (defined _MSC_VER) && (_MSC_VER == 1200) +# pragma warning (disable : 4786) // too long name, harmless warning +#endif + + +#include <exception> +#include <string> + +#include <boost/assert.hpp> + +#define BOOST_ARCHIVE_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/archive/xml_archive_exception.hpp> + +namespace boost { +namespace archive { + +BOOST_ARCHIVE_DECL +xml_archive_exception::xml_archive_exception( + exception_code c, + const char * e1, + const char * e2 + ) : + archive_exception(other_exception, e1, e2) + { + switch(c){ + case xml_archive_parsing_error: + archive_exception::append(0, "unrecognized XML syntax"); + break; + case xml_archive_tag_mismatch:{ + unsigned int l; + l = archive_exception::append(0, "XML start/end tag mismatch"); + if(NULL != e1){ + l = archive_exception::append(l, " - "); + archive_exception::append(l, e1); + } + break; + } + case xml_archive_tag_name_error: + archive_exception::append(0, "Invalid XML tag name"); + break; + default: + BOOST_ASSERT(false); + archive_exception::append(0, "programming error"); + break; + } + } + +BOOST_ARCHIVE_DECL +xml_archive_exception::xml_archive_exception(xml_archive_exception const & oth) : + archive_exception(oth) + { + } + +BOOST_ARCHIVE_DECL xml_archive_exception::~xml_archive_exception() BOOST_NOEXCEPT_OR_NOTHROW {} + +} // archive +} // boost diff --git a/src/boost/libs/serialization/src/xml_grammar.cpp b/src/boost/libs/serialization/src/xml_grammar.cpp new file mode 100644 index 00000000..ae48f70d --- /dev/null +++ b/src/boost/libs/serialization/src/xml_grammar.cpp @@ -0,0 +1,74 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// xml_grammar.cpp: + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#if (defined _MSC_VER) && (_MSC_VER == 1200) +# pragma warning (disable : 4786) // too long name, harmless warning +#endif + +#include <boost/config.hpp> + +#define BOOST_ARCHIVE_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/archive/impl/basic_xml_grammar.hpp> + +using namespace boost::spirit::classic; + +// fixup for borland +// The following code will be put into Boost.Config in a later revision +#if ! defined(__SGI_STL_PORT) \ +&& defined(BOOST_RWSTD_VER) && BOOST_RWSTD_VER<=0x020101 +#include <string> +namespace std { + template<> + inline string & + string::replace ( + char * first1, + char * last1, + const char * first2, + const char * last2 + ){ + replace(first1-begin(),last1-first1,first2,last2-first2,0,last2-first2); + return *this; + } +} // namespace std +#endif + +namespace boost { +namespace archive { + +typedef basic_xml_grammar<char> xml_grammar; + +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// specific definitions for char based XML + +template<> +void xml_grammar::init_chset(){ + Char = chset_t("\x9\xA\xD\x20-\x7f\x80\x81-\xFF"); + Letter = chset_t("\x41-\x5A\x61-\x7A\xC0-\xD6\xD8-\xF6\xF8-\xFF"); + Digit = chset_t("0-9"); + Extender = chset_t('\xB7'); + Sch = chset_t("\x20\x9\xD\xA"); + NameChar = Letter | Digit | chset_p("._:-") | Extender ; +} + +} // namespace archive +} // namespace boost + +#include "basic_xml_grammar.ipp" + +namespace boost { +namespace archive { + +// explicit instantiation of xml for 8 bit characters +template class basic_xml_grammar<char>; + +} // namespace archive +} // namespace boost + diff --git a/src/boost/libs/serialization/src/xml_iarchive.cpp b/src/boost/libs/serialization/src/xml_iarchive.cpp new file mode 100644 index 00000000..0a19a8e8 --- /dev/null +++ b/src/boost/libs/serialization/src/xml_iarchive.cpp @@ -0,0 +1,33 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// xml_iarchive.cpp: + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#if (defined _MSC_VER) && (_MSC_VER == 1200) +# pragma warning (disable : 4786) // too long name, harmless warning +#endif + +#define BOOST_ARCHIVE_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/archive/xml_iarchive.hpp> +#include <boost/archive/detail/archive_serializer_map.hpp> + +// explicitly instantiate for this type of xml stream +#include <boost/archive/impl/archive_serializer_map.ipp> +#include <boost/archive/impl/basic_xml_iarchive.ipp> +#include <boost/archive/impl/xml_iarchive_impl.ipp> + +namespace boost { +namespace archive { + +template class detail::archive_serializer_map<xml_iarchive>; +template class basic_xml_iarchive<xml_iarchive> ; +template class xml_iarchive_impl<xml_iarchive> ; + +} // namespace archive +} // namespace boost diff --git a/src/boost/libs/serialization/src/xml_oarchive.cpp b/src/boost/libs/serialization/src/xml_oarchive.cpp new file mode 100644 index 00000000..c238845d --- /dev/null +++ b/src/boost/libs/serialization/src/xml_oarchive.cpp @@ -0,0 +1,33 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// xml_oarchive.cpp: + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#if (defined _MSC_VER) && (_MSC_VER == 1200) +# pragma warning (disable : 4786) // too long name, harmless warning +#endif + +#define BOOST_ARCHIVE_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/archive/xml_oarchive.hpp> +#include <boost/archive/detail/archive_serializer_map.hpp> + +// explicitly instantiate for this type of xml stream +#include <boost/archive/impl/archive_serializer_map.ipp> +#include <boost/archive/impl/basic_xml_oarchive.ipp> +#include <boost/archive/impl/xml_oarchive_impl.ipp> + +namespace boost { +namespace archive { + +template class detail::archive_serializer_map<xml_oarchive>; +template class basic_xml_oarchive<xml_oarchive> ; +template class xml_oarchive_impl<xml_oarchive> ; + +} // namespace archive +} // namespace boost diff --git a/src/boost/libs/serialization/src/xml_wgrammar.cpp b/src/boost/libs/serialization/src/xml_wgrammar.cpp new file mode 100644 index 00000000..7c053e80 --- /dev/null +++ b/src/boost/libs/serialization/src/xml_wgrammar.cpp @@ -0,0 +1,157 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// xml_wgrammar.cpp: + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <boost/config.hpp> + +#ifdef BOOST_NO_STD_WSTREAMBUF +#error "wide char i/o not supported on this platform" +#else + +#define BOOST_WARCHIVE_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/archive/impl/basic_xml_grammar.hpp> + +using namespace boost::spirit::classic; + +// fixup for RogueWave +#if ! defined(__SGI_STL_PORT) \ +&& defined(BOOST_RWSTD_VER) && BOOST_RWSTD_VER<=0x020101 +#include <string> +namespace std { + template<> + inline wstring & + wstring::replace ( + wchar_t * first1, + wchar_t * last1, + const wchar_t * first2, + const wchar_t * last2 + ){ + replace(first1-begin(),last1-first1,first2,last2-first2,0,last2-first2); + return *this; + } +} // namespace std +#endif + +namespace boost { +namespace archive { + +typedef basic_xml_grammar<wchar_t> xml_wgrammar; + +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// specific definitions for wchar_t based XML + +template<> +void xml_wgrammar::init_chset(){ + Char = chset_t( + #if defined(__GNUC__) && defined(linux) + L"\x9\xA\xD\x20-\xD7FF\xE000-\xFFFD\x10000-\x10FFFF" + #else + L"\x9\xA\xD\x20-\xD7FF\xE000-\xFFFD" + #endif + ); + + Sch = chset_t(L"\x20\x9\xD\xA"); + + BaseChar = chset_t( + L"\x41-\x5A\x61-\x7A\xC0-\xD6\xD8-\xF6\xF8-\xFF\x100-\x131\x134-\x13E" + L"\x141-\x148\x14A-\x17E\x180-\x1C3\x1CD-\x1F0\x1F4-\x1F5\x1FA-\x217" + L"\x250-\x2A8\x2BB-\x2C1\x386\x388-\x38A\x38C\x38E-\x3A1\x3A3-\x3CE" + L"\x3D0-\x3D6\x3DA\x3DC\x3DE\x3E0\x3E2-\x3F3\x401-\x40C\x40E-\x44F" + L"\x451-\x45C\x45E-\x481\x490-\x4C4\x4C7-\x4C8\x4CB-\x4CC\x4D0-\x4EB" + L"\x4EE-\x4F5\x4F8-\x4F9\x531-\x556\x559\x561-\x586\x5D0-\x5EA" + L"\x5F0-\x5F2\x621-\x63A\x641-\x64A\x671-\x6B7\x6BA-\x6BE\x6C0-\x6CE" + L"\x6D0-\x6D3\x6D5\x6E5-\x6E6\x905-\x939\x93D\x958-\x961\x985-\x98C" + L"\x98F-\x990\x993-\x9A8\x9AA-\x9B0\x9B2\x9B6-\x9B9\x9DC-\x9DD" + L"\x9DF-\x9E1\x9F0-\x9F1\xA05-\xA0A\xA0F-\xA10\xA13-\xA28\xA2A-\xA30" + L"\xA32-\xA33\xA35-\xA36\xA38-\xA39\xA59-\xA5C\xA5E\xA72-\xA74" + L"\xA85-\xA8B\xA8D\xA8F-\xA91\xA93-\xAA8\xAAA-\xAB0\xAB2-\xAB3" + L"\xAB5-\xAB9\xABD\xAE0\xB05-\xB0C\xB0F-\xB10\xB13-\xB28\xB2A-\xB30" + L"\xB32-\xB33\xB36-\xB39\xB3D\xB5C-\xB5D\xB5F-\xB61\xB85-\xB8A" + L"\xB8E-\xB90\xB92-\xB95\xB99-\xB9A\xB9C\xB9E-\xB9F\xBA3-\xBA4" + L"\xBA8-\xBAA\xBAE-\xBB5\xBB7-\xBB9\xC05-\xC0C\xC0E-\xC10\xC12-\xC28" + L"\xC2A-\xC33\xC35-\xC39\xC60-\xC61\xC85-\xC8C\xC8E-\xC90\xC92-\xCA8" + L"\xCAA-\xCB3\xCB5-\xCB9\xCDE\xCE0-\xCE1\xD05-\xD0C\xD0E-\xD10" + L"\xD12-\xD28\xD2A-\xD39\xD60-\xD61\xE01-\xE2E\xE30\xE32-\xE33" + L"\xE40-\xE45\xE81-\xE82\xE84\xE87-\xE88\xE8A\xE8D\xE94-\xE97" + L"\xE99-\xE9F\xEA1-\xEA3\xEA5\xEA7\xEAA-\xEAB\xEAD-\xEAE\xEB0" + L"\xEB2-\xEB3\xEBD\xEC0-\xEC4\xF40-\xF47\xF49-\xF69\x10A0-\x10C5" + L"\x10D0-\x10F6\x1100\x1102-\x1103\x1105-\x1107\x1109\x110B-\x110C" + L"\x110E-\x1112\x113C\x113E\x1140\x114C\x114E\x1150\x1154-\x1155" + L"\x1159\x115F-\x1161\x1163\x1165\x1167\x1169\x116D-\x116E" + L"\x1172-\x1173\x1175\x119E\x11A8\x11AB\x11AE-\x11AF\x11B7-\x11B8" + L"\x11BA\x11BC-\x11C2\x11EB\x11F0\x11F9\x1E00-\x1E9B\x1EA0-\x1EF9" + L"\x1F00-\x1F15\x1F18-\x1F1D\x1F20-\x1F45\x1F48-\x1F4D\x1F50-\x1F57" + L"\x1F59\x1F5B\x1F5D\x1F5F-\x1F7D\x1F80-\x1FB4\x1FB6-\x1FBC\x1FBE" + L"\x1FC2-\x1FC4\x1FC6-\x1FCC\x1FD0-\x1FD3\x1FD6-\x1FDB\x1FE0-\x1FEC" + L"\x1FF2-\x1FF4\x1FF6-\x1FFC\x2126\x212A-\x212B\x212E\x2180-\x2182" + L"\x3041-\x3094\x30A1-\x30FA\x3105-\x312C\xAC00-\xD7A3" + ); + + Ideographic = chset_t(L"\x4E00-\x9FA5\x3007\x3021-\x3029"); + + Letter = BaseChar | Ideographic; + + CombiningChar = chset_t( + L"\x0300-\x0345\x0360-\x0361\x0483-\x0486\x0591-\x05A1\x05A3-\x05B9" + L"\x05BB-\x05BD\x05BF\x05C1-\x05C2\x05C4\x064B-\x0652\x0670" + L"\x06D6-\x06DC\x06DD-\x06DF\x06E0-\x06E4\x06E7-\x06E8\x06EA-\x06ED" + L"\x0901-\x0903\x093C\x093E-\x094C\x094D\x0951-\x0954\x0962-\x0963" + L"\x0981-\x0983\x09BC\x09BE\x09BF\x09C0-\x09C4\x09C7-\x09C8" + L"\x09CB-\x09CD\x09D7\x09E2-\x09E3\x0A02\x0A3C\x0A3E\x0A3F" + L"\x0A40-\x0A42\x0A47-\x0A48\x0A4B-\x0A4D\x0A70-\x0A71\x0A81-\x0A83" + L"\x0ABC\x0ABE-\x0AC5\x0AC7-\x0AC9\x0ACB-\x0ACD\x0B01-\x0B03\x0B3C" + L"\x0B3E-\x0B43\x0B47-\x0B48\x0B4B-\x0B4D\x0B56-\x0B57\x0B82-\x0B83" + L"\x0BBE-\x0BC2\x0BC6-\x0BC8\x0BCA-\x0BCD\x0BD7\x0C01-\x0C03" + L"\x0C3E-\x0C44\x0C46-\x0C48\x0C4A-\x0C4D\x0C55-\x0C56\x0C82-\x0C83" + L"\x0CBE-\x0CC4\x0CC6-\x0CC8\x0CCA-\x0CCD\x0CD5-\x0CD6\x0D02-\x0D03" + L"\x0D3E-\x0D43\x0D46-\x0D48\x0D4A-\x0D4D\x0D57\x0E31\x0E34-\x0E3A" + L"\x0E47-\x0E4E\x0EB1\x0EB4-\x0EB9\x0EBB-\x0EBC\x0EC8-\x0ECD" + L"\x0F18-\x0F19\x0F35\x0F37\x0F39\x0F3E\x0F3F\x0F71-\x0F84" + L"\x0F86-\x0F8B\x0F90-\x0F95\x0F97\x0F99-\x0FAD\x0FB1-\x0FB7\x0FB9" + L"\x20D0-\x20DC\x20E1\x302A-\x302F\x3099\x309A" + ); + + Digit = chset_t( + L"\x0030-\x0039\x0660-\x0669\x06F0-\x06F9\x0966-\x096F\x09E6-\x09EF" + L"\x0A66-\x0A6F\x0AE6-\x0AEF\x0B66-\x0B6F\x0BE7-\x0BEF\x0C66-\x0C6F" + L"\x0CE6-\x0CEF\x0D66-\x0D6F\x0E50-\x0E59\x0ED0-\x0ED9\x0F20-\x0F29" + ); + + Extender = chset_t( + L"\x00B7\x02D0\x02D1\x0387\x0640\x0E46\x0EC6\x3005\x3031-\x3035" + L"\x309D-\x309E\x30FC-\x30FE" + ); + + NameChar = + Letter + | Digit + | L'.' + | L'-' + | L'_' + | L':' + | CombiningChar + | Extender + ; +} +} // namespace archive +} // namespace boost + +#include "basic_xml_grammar.ipp" + +namespace boost { +namespace archive { + +// explicit instantiation of xml for wide characters +template class basic_xml_grammar<wchar_t>; + +} // namespace archive +} // namespace boost + +#endif diff --git a/src/boost/libs/serialization/src/xml_wiarchive.cpp b/src/boost/libs/serialization/src/xml_wiarchive.cpp new file mode 100644 index 00000000..8c60abf7 --- /dev/null +++ b/src/boost/libs/serialization/src/xml_wiarchive.cpp @@ -0,0 +1,40 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// xml_wiarchive.cpp: + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#if (defined _MSC_VER) && (_MSC_VER == 1200) +# pragma warning (disable : 4786) // too long name, harmless warning +#endif + +#include <boost/config.hpp> +#ifdef BOOST_NO_STD_WSTREAMBUF +#error "wide char i/o not supported on this platform" +#else + +#define BOOST_WARCHIVE_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/archive/xml_wiarchive.hpp> +#include <boost/archive/detail/archive_serializer_map.hpp> + +// explicitly instantiate for this type of xml stream +#include <boost/archive/impl/archive_serializer_map.ipp> +#include <boost/archive/impl/basic_xml_iarchive.ipp> +#include <boost/archive/impl/xml_wiarchive_impl.ipp> + +namespace boost { +namespace archive { + +template class detail::archive_serializer_map<xml_wiarchive>; +template class basic_xml_iarchive<xml_wiarchive> ; +template class xml_wiarchive_impl<xml_wiarchive> ; + +} // namespace archive +} // namespace boost + +#endif // BOOST_NO_STD_WSTREAMBUF diff --git a/src/boost/libs/serialization/src/xml_woarchive.cpp b/src/boost/libs/serialization/src/xml_woarchive.cpp new file mode 100644 index 00000000..f9b6ba38 --- /dev/null +++ b/src/boost/libs/serialization/src/xml_woarchive.cpp @@ -0,0 +1,40 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// xml_woarchive.cpp: + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#if (defined _MSC_VER) && (_MSC_VER == 1200) +# pragma warning (disable : 4786) // too long name, harmless warning +#endif + +#include <boost/config.hpp> +#ifdef BOOST_NO_STD_WSTREAMBUF +#error "wide char i/o not supported on this platform" +#else + +#define BOOST_WARCHIVE_SOURCE +#include <boost/serialization/config.hpp> +#include <boost/archive/xml_woarchive.hpp> +#include <boost/archive/detail/archive_serializer_map.hpp> + +// explicitly instantiate for this type of text stream +#include <boost/archive/impl/archive_serializer_map.ipp> +#include <boost/archive/impl/basic_xml_oarchive.ipp> +#include <boost/archive/impl/xml_woarchive_impl.ipp> + +namespace boost { +namespace archive { + +template class detail::archive_serializer_map<xml_woarchive>; +template class basic_xml_oarchive<xml_woarchive> ; +template class xml_woarchive_impl<xml_woarchive> ; + +} // namespace archive +} // namespace boost + +#endif // BOOST_NO_STD_WSTREAMBUF diff --git a/src/boost/libs/serialization/test/A.cpp b/src/boost/libs/serialization/test/A.cpp new file mode 100644 index 00000000..361681e3 --- /dev/null +++ b/src/boost/libs/serialization/test/A.cpp @@ -0,0 +1,218 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// A.cpp simple class test + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <cassert> +#include <cstdlib> // rand() +#include <cstddef> // size_t +#include <boost/math/special_functions/next.hpp> + +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::rand; + using ::size_t; +} +#endif + +#include <boost/detail/workaround.hpp> +#if BOOST_WORKAROUND(BOOST_DINKUMWARE_STDLIB, == 1) +#include <boost/archive/dinkumware.hpp> +#endif + +#include "A.hpp" + +template<class S> +void randomize(S &x) +{ + assert(0 == x.size()); + for(;;){ + unsigned int i = std::rand() % 27; + if(0 == i) + break; + x += static_cast<typename S::value_type>('a' - 1 + i); + } +} + +template<class T> +void accumulate(std::size_t & s, const T & t){ + const char * tptr = (const char *)(& t); + unsigned int count = sizeof(t); + while(count-- > 0){ + s += *tptr++; + } +} +A_DLL_DECL +A::operator std::size_t () const { + std::size_t retval = 0; + accumulate(retval, b); + #ifndef BOOST_NO_INT64_T + accumulate(retval, f); + accumulate(retval, g); + #endif + accumulate(retval, l); + accumulate(retval, m); + accumulate(retval, n); + accumulate(retval, o); + accumulate(retval, p); + accumulate(retval, q); + #ifndef BOOST_NO_CWCHAR + accumulate(retval, r); + #endif + accumulate(retval, c); + accumulate(retval, s); + accumulate(retval, t); + accumulate(retval, u); + accumulate(retval, v); + return retval; +} + +#if defined(_MSC_VER) +#pragma warning(push) // Save warning settings. +#pragma warning(disable : 4244) // Disable possible loss of data warning +#endif + +A_DLL_DECL +A::A() : + b(true), + #ifndef BOOST_NO_INT64_T + f(static_cast<boost::int64_t>(std::rand()) * static_cast<boost::int64_t>(std::rand())), + g(static_cast<boost::uint64_t>(std::rand()) * static_cast<boost::uint64_t>(std::rand())), + #endif + l(static_cast<enum h>(std::rand() % 3)), + m(std::rand()), + n(std::rand()), + o(std::rand()), + p(std::rand()), + q(std::rand()), + #ifndef BOOST_NO_CWCHAR + r(std::rand()), + #endif + c(0xff & std::rand()), + s(0xff & std::rand()), + t(0xff & std::rand()), + u(std::rand()), + v(std::rand()), + w((float)std::rand()), + x((double)std::rand()) +{ + randomize(y); + #ifndef BOOST_NO_STD_WSTRING + randomize(z); + #endif +} + +#if defined(_MSC_VER) +#pragma warning(pop) // Restore warnings to previous state. +#endif + +A_DLL_DECL bool +A::operator==(const A &rhs) const { + if(b != rhs.b) + return false; + if(l != rhs.l) + return false; + #ifndef BOOST_NO_INT64_T + if(f != rhs.f) + return false; + if(g != rhs.g) + return false; + #endif + if(m != rhs.m) + return false; + if(n != rhs.n) + return false; + if(o != rhs.o) + return false; + if(p != rhs.p) + return false; + if(q != rhs.q) + return false; + #ifndef BOOST_NO_CWCHAR + if(r != rhs.r) + return false; + #endif + if(c != rhs.c) + return false; + if(s != rhs.s) + return false; + if(t != rhs.t) + return false; + if(u != rhs.u) + return false; + if(v != rhs.v) + return false; + if(std::abs( boost::math::float_distance(w, rhs.w)) > 1) + return false; + if(std::abs( boost::math::float_distance(x, rhs.x)) > 1) + return false; + if(0 != y.compare(rhs.y)) + return false; + #ifndef BOOST_NO_STD_WSTRING + if(0 != z.compare(rhs.z)) + return false; + #endif + return true; +} + +A_DLL_DECL bool +A::operator!=(const A &rhs) const { + return ! (*this == rhs); +} + +A_DLL_DECL bool +A::operator<(const A &rhs) const { + if(b != rhs.b) + return b < rhs.b; + #ifndef BOOST_NO_INT64_T + if(f != rhs.f) + return f < rhs.f; + if(g != rhs.g) + return g < rhs.g; + #endif + if(l != rhs.l ) + return l < rhs.l; + if(m != rhs.m ) + return m < rhs.m; + if(n != rhs.n ) + return n < rhs.n; + if(o != rhs.o ) + return o < rhs.o; + if(p != rhs.p ) + return p < rhs.p; + if(q != rhs.q ) + return q < rhs.q; + #ifndef BOOST_NO_CWCHAR + if(r != rhs.r ) + return r < rhs.r; + #endif + if(c != rhs.c ) + return c < rhs.c; + if(s != rhs.s ) + return s < rhs.s; + if(t != rhs.t ) + return t < rhs.t; + if(u != rhs.u ) + return u < rhs.u; + if(v != rhs.v ) + return v < rhs.v; + if(w != rhs.w ) + return w < rhs.w; + if(x != rhs.x ) + return x < rhs.x; + int i = y.compare(rhs.y); + if(i != 0 ) + return i < 0; + #ifndef BOOST_NO_STD_WSTRING + int j = z.compare(rhs.z); + if(j != 0 ) + return j < 0; + #endif + return false; +} diff --git a/src/boost/libs/serialization/test/A.hpp b/src/boost/libs/serialization/test/A.hpp new file mode 100644 index 00000000..a6aa05b6 --- /dev/null +++ b/src/boost/libs/serialization/test/A.hpp @@ -0,0 +1,95 @@ +#ifndef BOOST_SERIALIZATION_TEST_A_HPP +#define BOOST_SERIALIZATION_TEST_A_HPP + +// MS compatible compilers support #pragma once +#if defined(_MSC_VER) +# pragma once +#endif + +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// A.hpp simple class test + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <ostream> // for friend output operators +#include <cstddef> // size_t +#include <boost/config.hpp> + +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::size_t; +} +#endif + +#include <boost/limits.hpp> +#include <boost/cstdint.hpp> + +#include <boost/serialization/access.hpp> +#include <boost/serialization/string.hpp> + +#if defined(A_IMPORT) + #define A_DLL_DECL BOOST_SYMBOL_IMPORT + #pragma message("A imported") +#elif defined(A_EXPORT) + #define A_DLL_DECL BOOST_SYMBOL_EXPORT + #pragma message ("A exported") +#endif + +#ifndef A_DLL_DECL + #define A_DLL_DECL +#endif + +class A_DLL_DECL A { +private: + friend class boost::serialization::access; + template<class Archive> + void serialize( + Archive &ar, + const unsigned int /* file_version */ + ); + bool b; + #ifndef BOOST_NO_INT64_T + boost::int64_t f; + boost::uint64_t g; + #endif + enum h { + i = 0, + j, + k + } l; + std::size_t m; + signed long n; + unsigned long o; + signed short p; + unsigned short q; + #ifndef BOOST_NO_CWCHAR + wchar_t r; + #endif + char c; + signed char s; + unsigned char t; + signed int u; + unsigned int v; + float w; + double x; + std::string y; + #ifndef BOOST_NO_STD_WSTRING + std::wstring z; + #endif +public: + A(); + bool check_equal(const A &rhs) const; + bool operator==(const A &rhs) const; + bool operator!=(const A &rhs) const; + bool operator<(const A &rhs) const; // used by less + // hash function for class A + operator std::size_t () const; + friend std::ostream & operator<<(std::ostream & os, A const & a); +}; + +#endif // BOOST_SERIALIZATION_TEST_A_HPP diff --git a/src/boost/libs/serialization/test/A.ipp b/src/boost/libs/serialization/test/A.ipp new file mode 100644 index 00000000..552e5fa1 --- /dev/null +++ b/src/boost/libs/serialization/test/A.ipp @@ -0,0 +1,60 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// A.ipp simple class test + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#if BOOST_WORKAROUND(BOOST_DINKUMWARE_STDLIB, == 1) +#include <boost/archive/dinkumware.hpp> +#endif + +#include <boost/serialization/nvp.hpp> +#include "A.hpp" + +template<class Archive> +void A::serialize( + Archive &ar, + const unsigned int /* file_version */ +){ + ar & BOOST_SERIALIZATION_NVP(b); + #ifndef BOOST_NO_INT64_T + ar & BOOST_SERIALIZATION_NVP(f); + ar & BOOST_SERIALIZATION_NVP(g); + #endif + #if BOOST_WORKAROUND(__BORLANDC__, <= 0x551 ) + int i; + if(BOOST_DEDUCED_TYPENAME Archive::is_saving::value){ + i = l; + ar & BOOST_SERIALIZATION_NVP(i); + } + else{ + ar & BOOST_SERIALIZATION_NVP(i); + l = i; + } + #else + ar & BOOST_SERIALIZATION_NVP(l); + #endif + ar & BOOST_SERIALIZATION_NVP(m); + ar & BOOST_SERIALIZATION_NVP(n); + ar & BOOST_SERIALIZATION_NVP(o); + ar & BOOST_SERIALIZATION_NVP(p); + ar & BOOST_SERIALIZATION_NVP(q); + #ifndef BOOST_NO_CWCHAR + ar & BOOST_SERIALIZATION_NVP(r); + #endif + ar & BOOST_SERIALIZATION_NVP(c); + ar & BOOST_SERIALIZATION_NVP(s); + ar & BOOST_SERIALIZATION_NVP(t); + ar & BOOST_SERIALIZATION_NVP(u); + ar & BOOST_SERIALIZATION_NVP(v); + ar & BOOST_SERIALIZATION_NVP(w); + ar & BOOST_SERIALIZATION_NVP(x); + ar & BOOST_SERIALIZATION_NVP(y); + #ifndef BOOST_NO_STD_WSTRING + ar & BOOST_SERIALIZATION_NVP(z); + #endif +} diff --git a/src/boost/libs/serialization/test/B.hpp b/src/boost/libs/serialization/test/B.hpp new file mode 100644 index 00000000..02329091 --- /dev/null +++ b/src/boost/libs/serialization/test/B.hpp @@ -0,0 +1,115 @@ +#ifndef BOOST_SERIALIZATION_TEST_B_HPP +#define BOOST_SERIALIZATION_TEST_B_HPP + +// MS compatible compilers support #pragma once +#if defined(_MSC_VER) +# pragma once +#endif + +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// B.hpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <cstdlib> // for rand() +#include <cmath> +#include <boost/math/special_functions/next.hpp> + +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::rand; +} +#endif + +#include <boost/serialization/version.hpp> +#include <boost/serialization/split_member.hpp> +#include <boost/serialization/base_object.hpp> + +#include "A.hpp" + +/////////////////////////////////////////////////////// +// Derived class test +class B : public A +{ +private: + friend class boost::serialization::access; + template<class Archive> + void save(Archive &ar, const unsigned int /* file_version */) const + { + // write any base class info to the archive + ar << BOOST_SERIALIZATION_BASE_OBJECT_NVP(A); + + // write out members + ar << BOOST_SERIALIZATION_NVP(s); + ar << BOOST_SERIALIZATION_NVP(t); + ar << BOOST_SERIALIZATION_NVP(u); + ar << BOOST_SERIALIZATION_NVP(v); + ar << BOOST_SERIALIZATION_NVP(w); + ar << BOOST_SERIALIZATION_NVP(x); + } + + template<class Archive> + void load(Archive & ar, const unsigned int file_version) + { + // read any base class info to the archive + ar >> BOOST_SERIALIZATION_BASE_OBJECT_NVP(A); + switch(file_version){ + case 1: + case 2: + ar >> BOOST_SERIALIZATION_NVP(s); + ar >> BOOST_SERIALIZATION_NVP(t); + ar >> BOOST_SERIALIZATION_NVP(u); + ar >> BOOST_SERIALIZATION_NVP(v); + ar >> BOOST_SERIALIZATION_NVP(w); + ar >> BOOST_SERIALIZATION_NVP(x); + break; + default: + break; + } + } + + BOOST_SERIALIZATION_SPLIT_MEMBER() + signed char s; + unsigned char t; + signed int u; + unsigned int v; + float w; + double x; +public: + B(); + virtual ~B(){}; + bool operator==(const B &rhs) const; +}; + +B::B() : + s(static_cast<signed char>(std::rand())), + t(static_cast<unsigned char>(std::rand())), + u(std::rand()), + v(std::rand()), + w((float)std::rand() / std::rand()), + x((double)std::rand() / std::rand()) +{ +} + +BOOST_CLASS_VERSION(B, 2) + +inline bool B::operator==(const B &rhs) const +{ + return + A::operator==(rhs) + && s == rhs.s + && t == rhs.t + && u == rhs.u + && v == rhs.v + && std::abs( boost::math::float_distance(w, rhs.w)) < 2 + && std::abs( boost::math::float_distance(x, rhs.x)) < 2 + ; +} + +#endif // BOOST_SERIALIZATION_TEST_B_HPP diff --git a/src/boost/libs/serialization/test/C.hpp b/src/boost/libs/serialization/test/C.hpp new file mode 100644 index 00000000..7884a2be --- /dev/null +++ b/src/boost/libs/serialization/test/C.hpp @@ -0,0 +1,68 @@ +#ifndef BOOST_SERIALIZATION_TEST_A_HPP +#define BOOST_SERIALIZATION_TEST_A_HPP + +// MS compatible compilers support #pragma once +#if defined(_MSC_VER) +# pragma once +#endif + +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// C.hpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <boost/config.hpp> +#include <boost/serialization/traits.hpp> +#include <boost/serialization/split.hpp> + +#include "B.hpp" + +/////////////////////////////////////////////////////// +// Contained class +class C +{ +private: + friend class boost::serialization::access; + template<class Archive> + void save(Archive &ar, boost::archive::version_type file_version) const; + template<class Archive> + void load(Archive & ar, boost::archive::version_type file_version); + BOOST_SERIALIZATION_MEMBER_SPLIT() + B b; +public: + bool operator==(const C &rhs) const; +}; + +BOOST_CLASS_VERSION(C, 1) + +inline bool C::operator==(const C &rhs) const +{ + return b == rhs.b; +} + +template<class Archive> +inline void save(Archive &ar, boost::archive::version_type file_version) const +{ + ar << b; +} + +template<class Archive> +inline void load(Archive & ar, boost::archive::version_type file_version){ +{ + switch(file_version){ + case 1: + ar >> b; + break; + case 2: + default: + assert(false); + break; + } +} + +#endif // BOOST_SERIALIZATION_TEST_C_HPP diff --git a/src/boost/libs/serialization/test/D.hpp b/src/boost/libs/serialization/test/D.hpp new file mode 100644 index 00000000..bb6b86d3 --- /dev/null +++ b/src/boost/libs/serialization/test/D.hpp @@ -0,0 +1,88 @@ +#ifndef BOOST_SERIALIZATION_TEST_D_HPP +#define BOOST_SERIALIZATION_TEST_D_HPP + +// MS compatible compilers support #pragma once +#if defined(_MSC_VER) +# pragma once +#endif + +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// D.hpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <cstddef> // NULL + +#include "test_tools.hpp" +#include <boost/detail/no_exceptions_support.hpp> +#include <boost/serialization/throw_exception.hpp> +#include <boost/serialization/split_member.hpp> + +#include "B.hpp" + +/////////////////////////////////////////////////////// +// Contained class with multiple identical pointers +class D +{ +private: + friend class boost::serialization::access; + B *b1; + B *b2; + template<class Archive> + void save(Archive &ar, const unsigned int file_version) const{ + ar << BOOST_SERIALIZATION_NVP(b1); + ar << BOOST_SERIALIZATION_NVP(b2); + } + + template<class Archive> + void load(Archive & ar, const unsigned int file_version){ + BOOST_TRY { + ar >> boost::serialization::make_nvp("b", b1); + ar >> boost::serialization::make_nvp("b", b2); + } + BOOST_CATCH (...){ + // eliminate invalid pointers + b1 = NULL; + b2 = NULL; + BOOST_FAIL( "multiple identical pointers failed to load" ); + } + BOOST_CATCH_END + // check that loading was correct + BOOST_CHECK(b1 == b2); + } + + BOOST_SERIALIZATION_SPLIT_MEMBER() +public: + D(); + ~D(); + bool operator==(const D &rhs) const; +}; + +BOOST_CLASS_VERSION(D, 3) + +D::D() +{ + b1 = new B(); + b2 = b1; +} + +D::~D() +{ + delete b1; +} + +bool D::operator==(const D &rhs) const +{ + if(! (*b1 == *(rhs.b1)) ) + return false; + if(! (*b2 == *(rhs.b2)) ) + return false; + return true; +} + +#endif // BOOST_SERIALIZATION_TEST_D_HPP diff --git a/src/boost/libs/serialization/test/J.hpp b/src/boost/libs/serialization/test/J.hpp new file mode 100644 index 00000000..81018053 --- /dev/null +++ b/src/boost/libs/serialization/test/J.hpp @@ -0,0 +1,51 @@ +#ifndef BOOST_SERIALIZATION_TEST_J_HPP +#define BOOST_SERIALIZATION_TEST_J_HPP + +// MS compatible compilers support #pragma once +#if defined(_MSC_VER) +# pragma once +#endif + +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// J.hpp simple class test + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <boost/serialization/base_object.hpp> + +#include "A.hpp" + +/////////////////////////////////////////////////////// +// class with a member which refers to itself +class J : public A +{ +private: + friend class boost::serialization::access; + template<class Archive> + void serialize( + Archive &ar, + const unsigned int /* file_version */ + ){ + ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(A); + ar & BOOST_SERIALIZATION_NVP(j); + } +public: + bool operator==(const J &rhs) const; + J *j; + J(J *_j) : j(_j) {} + J() : j(NULL){} +}; + +BOOST_CLASS_VERSION(J, 6) + +bool J::operator==(const J &rhs) const +{ + return static_cast<const A &>(*this) == static_cast<const A &>(rhs); +} + +#endif // BOOST_SERIALIZATION_TEST_J_HPP diff --git a/src/boost/libs/serialization/test/Jamfile.v2 b/src/boost/libs/serialization/test/Jamfile.v2 new file mode 100644 index 00000000..cce15216 --- /dev/null +++ b/src/boost/libs/serialization/test/Jamfile.v2 @@ -0,0 +1,190 @@ +# Boost serialization Library test Jamfile + +# (C) Copyright Robert Ramey 2002-2004. +# Use, modification, and distribution are subject to the +# Boost Software License, Version 1.0. (See accompanying file +# LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) +# + +project libs/serialization/test + : id serialization_test + : requirements <library>/boost/filesystem + ; + +# import rules for testing conditional on config file variables +import ../../config/checks/config : requires ; + +# import rules from the boost serialization test +import ../util/test : + run-template + run-invoke + run-winvoke + test-bsl-run-no-lib + test-bsl-run + test-bsl-run_archive + test-bsl-run_files + test-bsl-run_polymorphic_files +; + +BOOST_ARCHIVE_LIST = [ modules.peek : BOOST_ARCHIVE_LIST ] ; + +lib dll_a + : + dll_a.cpp + ../build//boost_serialization + : + <link>shared + ; + +lib dll_polymorphic_base + : + dll_polymorphic_base.cpp + ../build//boost_serialization + : + <link>shared + ; + +lib dll_polymorphic_derived2 + : + dll_polymorphic_derived2.cpp + dll_polymorphic_base + ../build//boost_serialization + : + <link>shared + ; + +test-suite "serialization" : + [ test-bsl-run_files test_array : A : : [ requires cxx11_hdr_array ] ] # BOOST_NO_CXX11_HDR_ARRAY + [ test-bsl-run_files test_boost_array : A ] + [ test-bsl-run_files test_native_array : A ] + [ test-bsl-run_files test_binary ] + [ test-bsl-run_files test_class_info_save ] + [ test-bsl-run_files test_class_info_load ] + [ test-bsl-run_files test_bitset ] + [ test-bsl-run_files test_complex ] + [ test-bsl-run_files test_contained_class : A ] + [ test-bsl-run_files test_cyclic_ptrs : A ] + [ test-bsl-run_files test_delete_pointer ] + [ test-bsl-run_files test_deque : A ] + [ test-bsl-run_files test_derived ] + [ test-bsl-run_files test_derived_class : A ] + [ test-bsl-run_files test_derived_class_ptr : A ] + [ test-bsl-run_files test_diamond ] + [ test-bsl-run_files test_diamond_complex ] + [ test-bsl-run_files test_forward_list : A : : [ requires cxx11_hdr_forward_list ] ] # BOOST_NO_CXX11_HDR_FORWARD_LIST + [ test-bsl-run_files test_forward_list_ptrs : A : : [ requires cxx11_hdr_forward_list ] ] # BOOST_NO_CXX11_HDR_FORWARD_LIST + [ test-bsl-run_files test_helper_support ] + [ test-bsl-run_files test_interrupts ] + [ test-bsl-run_files test_list : A ] + [ test-bsl-run_files test_list_ptrs : A ] + [ test-bsl-run_files test_map : A ] + [ test-bsl-run_files test_map_hashed : A : : [ requires hash ] ] # BOOST_HAS_HASH + [ test-bsl-run_files test_map_unordered : A : : [ requires cxx11_hdr_unordered_map ] ] # BOOST_NO_CXX11_HDR_UNORDERED_MAP + [ test-bsl-run_files test_map_boost_unordered : A ] + [ test-bsl-run_files test_mi ] + [ test-bsl-run_files test_multiple_ptrs : A ] + [ test-bsl-run_files test_multiple_inheritance ] + [ test-bsl-run_files test_non_intrusive ] + [ test-bsl-run_files test_non_default_ctor ] + [ test-bsl-run_files test_non_default_ctor2 ] + [ test-bsl-run_files test_null_ptr ] + [ test-bsl-run_files test_nvp : A ] + [ test-bsl-run_files test_object ] + [ test-bsl-run_files test_primitive ] + [ test-bsl-run_files test_priority_queue : A ] + [ test-bsl-run_files test_queue : A ] + [ test-bsl-run_files test_recursion : A ] + [ test-bsl-run_files test_registered ] + [ test-bsl-run_files test_set : A ] + [ test-bsl-run_files test_set_hashed : A : : [ requires hash ] ] # BOOST_HAS_HASH + [ test-bsl-run_files test_set_unordered : A : : [ requires cxx11_hdr_unordered_set ] ] # BOOST_NO_CXX11_HDR_UNORDERED_SET + [ test-bsl-run_files test_set_boost_unordered : A ] + [ test-bsl-run_files test_simple_class : A ] + [ test-bsl-run_files test_simple_class_ptr : A ] + [ test-bsl-run_files test_slist : A : : [ requires slist ] ] # BOOST_HAS_SLIST ] + [ test-bsl-run_files test_slist_ptrs : A : : [ requires slist ] ] # BOOST_HAS_SLIST ] ] + [ test-bsl-run_files test_split ] + [ test-bsl-run_files test_stack : A ] + [ test-bsl-run_files test_tracking ] + [ test-bsl-run_files test_unregistered ] + [ test-bsl-run_files test_unique_ptr ] + [ test-bsl-run_files test_valarray ] + [ test-bsl-run_files test_variant : A ] + [ test-bsl-run_files test_vector : A ] + [ test-bsl-run_files test_new_operator : A ] + [ test-bsl-run_files test_optional ] + [ test-bsl-run_files test_shared_ptr ] + [ test-bsl-run_files test_shared_ptr_multi_base ] + [ test-bsl-run_files test_shared_ptr_132 : : : [ requires auto_ptr ] ] # BOOST_NO_AUTO_PTR + + [ test-bsl-run_polymorphic_files test_polymorphic : test_polymorphic_A A ] + [ test-bsl-run_polymorphic_files test_polymorphic2 : test_polymorphic2imp ] + [ test-bsl-run_polymorphic_files test_p_helper ] + + # this test should pass with both shared and static linking. But B2 get's mixed up with static linking + # so we'll just run the shared version of the test, which is the one that we're most interested + # in anyway. + [ test-bsl-run_polymorphic_files test_dll_exported : polymorphic_derived1 : dll_polymorphic_base dll_polymorphic_derived2 : <link>static:<build>no ] + + [ test-bsl-run_polymorphic_files test_no_rtti : polymorphic_base polymorphic_derived1 polymorphic_derived2 ] + [ test-bsl-run_polymorphic_files test_exported : polymorphic_base polymorphic_derived1 polymorphic_derived2 ] + + # should compile + [ compile test_strong_typedef.cpp ] + ; + +if ! $(BOOST_ARCHIVE_LIST) { + test-suite "serialization2" : + [ test-bsl-run test_inclusion ] + [ test-bsl-run test_inclusion2 ] + # boost build has the feature that the building if libraries vs dll is automatic + # in that dependent libraries are built the same way - shared/static - that + # the application is. On some platforms (e.g windows) this is required to avoid + # problems of linking incompatible versions of the runtime library. So + # we suppress tests of our dlls when using static libraries + + [ test-bsl-run test_dll_simple : : dll_a : <link>static:<build>no ] + # [ test-bsl-run test_dll_plugin : : dll_derived2 : <link>static:<build>no <target-os>linux:<linkflags>-ldl ] + + [ test-bsl-run test_private_ctor ] + [ test-bsl-run test_reset_object_address : A ] + [ test-bsl-run test_void_cast ] + [ test-bsl-run test_mult_archive_types ] + [ test-bsl-run test_iterators ] + [ test-bsl-run test_iterators_base64 ] + [ test-bsl-run test_smart_cast ] + [ test-bsl-run test_codecvt_null ] + [ test-bsl-run test_singleton ] + [ test-bsl-run test_singleton_inherited ] + [ test-bsl-run test_singleton_plain ] + + # [ test-bsl-run test_z ] + + # should fail compilation + [ compile-fail test_not_serializable.cpp ] + [ compile-fail test_traits_fail.cpp ] + [ compile-fail test_const_load_fail1.cpp ] + [ compile-fail test_const_load_fail2.cpp ] + [ compile-fail test_const_load_fail3.cpp ] + [ compile-fail test_const_load_fail1_nvp.cpp ] + [ compile-fail test_const_load_fail2_nvp.cpp ] + [ compile-fail test_const_load_fail3_nvp.cpp ] + [ compile-fail test_check.cpp ] + + # should compile with a warning message + [ compile test_static_warning.cpp ] + [ compile test_const_save_warn1.cpp ] + [ compile test_const_save_warn2.cpp ] + [ compile test_const_save_warn3.cpp ] + + # note - library unable to detect these errors for now + #[ compile test_const_save_warn1_nvp.cpp ] + #[ compile test_const_save_warn2_nvp.cpp ] + #[ compile test_const_save_warn3_nvp.cpp ] + + # should compile + [ compile test_traits_pass.cpp ] + [ compile test_const_pass.cpp ] + ; +} + diff --git a/src/boost/libs/serialization/test/b2.log b/src/boost/libs/serialization/test/b2.log new file mode 100644 index 00000000..03e7510b --- /dev/null +++ b/src/boost/libs/serialization/test/b2.log @@ -0,0 +1,2571 @@ +warning: mismatched versions of Boost.Build engine and core +warning: Boost.Build engine (b2) is 2018.02.00 +warning: Boost.Build core (at /Users/robertramey/WorkingProjects/modular-boost/tools/build/src) is 4.0-git +polymorphic_text_archive +polymorphic_text_warchive +polymorphic_binary_archive +polymorphic_xml_archive +polymorphic_xml_warchive +polymorphic_text_archive +polymorphic_text_warchive +polymorphic_binary_archive +polymorphic_xml_archive +polymorphic_xml_warchive +polymorphic_text_archive +polymorphic_text_warchive +polymorphic_binary_archive +polymorphic_xml_archive +polymorphic_xml_warchive +polymorphic_text_archive +polymorphic_text_warchive +polymorphic_binary_archive +polymorphic_xml_archive +polymorphic_xml_warchive +polymorphic_text_archive +polymorphic_text_warchive +polymorphic_binary_archive +polymorphic_xml_archive +polymorphic_xml_warchive +polymorphic_text_archive +polymorphic_text_warchive +polymorphic_binary_archive +polymorphic_xml_archive +polymorphic_xml_warchive +Performing configuration checks + + - default address-model : 64-bit (cached) + - default architecture : x86 (cached) + - symlinks supported : yes (cached) + - Boost.Config Feature Check: cxx11_hdr_array : yes (cached) + - Boost.Config Feature Check: std_wstreambuf : yes (cached) + - Boost.Config Feature Check: cxx11_hdr_forward_list : yes (cached) + - Boost.Config Feature Check: hash : no (cached) + - Boost.Config Feature Check: cxx11_hdr_unordered_map : no (cached) + - Boost.Config Feature Check: cxx11_hdr_unordered_set : no (cached) + - Boost.Config Feature Check: slist : no (cached) + - Boost.Config Feature Check: auto_ptr : yes (cached) +boost-test(RUN) "serialization/test_array_text_archive" : "libs/serialization/test/test_array.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_array_text_warchive" : "libs/serialization/test/test_array.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_array_binary_archive" : "libs/serialization/test/test_array.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_array_xml_archive" : "libs/serialization/test/test_array.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_array_xml_warchive" : "libs/serialization/test/test_array.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_boost_array_text_archive" : "libs/serialization/test/test_boost_array.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_boost_array_text_warchive" : "libs/serialization/test/test_boost_array.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_boost_array_binary_archive" : "libs/serialization/test/test_boost_array.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_boost_array_xml_archive" : "libs/serialization/test/test_boost_array.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_boost_array_xml_warchive" : "libs/serialization/test/test_boost_array.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_native_array_text_archive" : "libs/serialization/test/test_native_array.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_native_array_text_warchive" : "libs/serialization/test/test_native_array.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_native_array_binary_archive" : "libs/serialization/test/test_native_array.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_native_array_xml_archive" : "libs/serialization/test/test_native_array.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_native_array_xml_warchive" : "libs/serialization/test/test_native_array.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_binary_text_archive" : "libs/serialization/test/test_binary.cpp" +boost-test(RUN) "serialization/test_binary_text_warchive" : "libs/serialization/test/test_binary.cpp" +boost-test(RUN) "serialization/test_binary_binary_archive" : "libs/serialization/test/test_binary.cpp" +boost-test(RUN) "serialization/test_binary_xml_archive" : "libs/serialization/test/test_binary.cpp" +boost-test(RUN) "serialization/test_binary_xml_warchive" : "libs/serialization/test/test_binary.cpp" +boost-test(RUN) "serialization/test_class_info_save_text_archive" : "libs/serialization/test/test_class_info_save.cpp" +boost-test(RUN) "serialization/test_class_info_save_text_warchive" : "libs/serialization/test/test_class_info_save.cpp" +boost-test(RUN) "serialization/test_class_info_save_binary_archive" : "libs/serialization/test/test_class_info_save.cpp" +boost-test(RUN) "serialization/test_class_info_save_xml_archive" : "libs/serialization/test/test_class_info_save.cpp" +boost-test(RUN) "serialization/test_class_info_save_xml_warchive" : "libs/serialization/test/test_class_info_save.cpp" +boost-test(RUN) "serialization/test_class_info_load_text_archive" : "libs/serialization/test/test_class_info_load.cpp" +boost-test(RUN) "serialization/test_class_info_load_text_warchive" : "libs/serialization/test/test_class_info_load.cpp" +boost-test(RUN) "serialization/test_class_info_load_binary_archive" : "libs/serialization/test/test_class_info_load.cpp" +boost-test(RUN) "serialization/test_class_info_load_xml_archive" : "libs/serialization/test/test_class_info_load.cpp" +boost-test(RUN) "serialization/test_class_info_load_xml_warchive" : "libs/serialization/test/test_class_info_load.cpp" +boost-test(RUN) "serialization/test_bitset_text_archive" : "libs/serialization/test/test_bitset.cpp" +boost-test(RUN) "serialization/test_bitset_text_warchive" : "libs/serialization/test/test_bitset.cpp" +boost-test(RUN) "serialization/test_bitset_binary_archive" : "libs/serialization/test/test_bitset.cpp" +boost-test(RUN) "serialization/test_bitset_xml_archive" : "libs/serialization/test/test_bitset.cpp" +boost-test(RUN) "serialization/test_bitset_xml_warchive" : "libs/serialization/test/test_bitset.cpp" +boost-test(RUN) "serialization/test_complex_text_archive" : "libs/serialization/test/test_complex.cpp" +boost-test(RUN) "serialization/test_complex_text_warchive" : "libs/serialization/test/test_complex.cpp" +boost-test(RUN) "serialization/test_complex_binary_archive" : "libs/serialization/test/test_complex.cpp" +boost-test(RUN) "serialization/test_complex_xml_archive" : "libs/serialization/test/test_complex.cpp" +boost-test(RUN) "serialization/test_complex_xml_warchive" : "libs/serialization/test/test_complex.cpp" +boost-test(RUN) "serialization/test_contained_class_text_archive" : "libs/serialization/test/test_contained_class.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_contained_class_text_warchive" : "libs/serialization/test/test_contained_class.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_contained_class_binary_archive" : "libs/serialization/test/test_contained_class.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_contained_class_xml_archive" : "libs/serialization/test/test_contained_class.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_contained_class_xml_warchive" : "libs/serialization/test/test_contained_class.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_cyclic_ptrs_text_archive" : "libs/serialization/test/test_cyclic_ptrs.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_cyclic_ptrs_text_warchive" : "libs/serialization/test/test_cyclic_ptrs.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_cyclic_ptrs_binary_archive" : "libs/serialization/test/test_cyclic_ptrs.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_cyclic_ptrs_xml_archive" : "libs/serialization/test/test_cyclic_ptrs.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_cyclic_ptrs_xml_warchive" : "libs/serialization/test/test_cyclic_ptrs.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_delete_pointer_text_archive" : "libs/serialization/test/test_delete_pointer.cpp" +boost-test(RUN) "serialization/test_delete_pointer_text_warchive" : "libs/serialization/test/test_delete_pointer.cpp" +boost-test(RUN) "serialization/test_delete_pointer_binary_archive" : "libs/serialization/test/test_delete_pointer.cpp" +boost-test(RUN) "serialization/test_delete_pointer_xml_archive" : "libs/serialization/test/test_delete_pointer.cpp" +boost-test(RUN) "serialization/test_delete_pointer_xml_warchive" : "libs/serialization/test/test_delete_pointer.cpp" +boost-test(RUN) "serialization/test_deque_text_archive" : "libs/serialization/test/test_deque.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_deque_text_warchive" : "libs/serialization/test/test_deque.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_deque_binary_archive" : "libs/serialization/test/test_deque.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_deque_xml_archive" : "libs/serialization/test/test_deque.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_deque_xml_warchive" : "libs/serialization/test/test_deque.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_derived_text_archive" : "libs/serialization/test/test_derived.cpp" +boost-test(RUN) "serialization/test_derived_text_warchive" : "libs/serialization/test/test_derived.cpp" +boost-test(RUN) "serialization/test_derived_binary_archive" : "libs/serialization/test/test_derived.cpp" +boost-test(RUN) "serialization/test_derived_xml_archive" : "libs/serialization/test/test_derived.cpp" +boost-test(RUN) "serialization/test_derived_xml_warchive" : "libs/serialization/test/test_derived.cpp" +boost-test(RUN) "serialization/test_derived_class_text_archive" : "libs/serialization/test/test_derived_class.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_derived_class_text_warchive" : "libs/serialization/test/test_derived_class.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_derived_class_binary_archive" : "libs/serialization/test/test_derived_class.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_derived_class_xml_archive" : "libs/serialization/test/test_derived_class.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_derived_class_xml_warchive" : "libs/serialization/test/test_derived_class.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_derived_class_ptr_text_archive" : "libs/serialization/test/test_derived_class_ptr.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_derived_class_ptr_text_warchive" : "libs/serialization/test/test_derived_class_ptr.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_derived_class_ptr_binary_archive" : "libs/serialization/test/test_derived_class_ptr.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_derived_class_ptr_xml_archive" : "libs/serialization/test/test_derived_class_ptr.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_derived_class_ptr_xml_warchive" : "libs/serialization/test/test_derived_class_ptr.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_diamond_text_archive" : "libs/serialization/test/test_diamond.cpp" +boost-test(RUN) "serialization/test_diamond_text_warchive" : "libs/serialization/test/test_diamond.cpp" +boost-test(RUN) "serialization/test_diamond_binary_archive" : "libs/serialization/test/test_diamond.cpp" +boost-test(RUN) "serialization/test_diamond_xml_archive" : "libs/serialization/test/test_diamond.cpp" +boost-test(RUN) "serialization/test_diamond_xml_warchive" : "libs/serialization/test/test_diamond.cpp" +boost-test(RUN) "serialization/test_diamond_complex_text_archive" : "libs/serialization/test/test_diamond_complex.cpp" +boost-test(RUN) "serialization/test_diamond_complex_text_warchive" : "libs/serialization/test/test_diamond_complex.cpp" +boost-test(RUN) "serialization/test_diamond_complex_binary_archive" : "libs/serialization/test/test_diamond_complex.cpp" +boost-test(RUN) "serialization/test_diamond_complex_xml_archive" : "libs/serialization/test/test_diamond_complex.cpp" +boost-test(RUN) "serialization/test_diamond_complex_xml_warchive" : "libs/serialization/test/test_diamond_complex.cpp" +boost-test(RUN) "serialization/test_forward_list_text_archive" : "libs/serialization/test/test_forward_list.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_forward_list_text_warchive" : "libs/serialization/test/test_forward_list.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_forward_list_binary_archive" : "libs/serialization/test/test_forward_list.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_forward_list_xml_archive" : "libs/serialization/test/test_forward_list.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_forward_list_xml_warchive" : "libs/serialization/test/test_forward_list.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_forward_list_ptrs_text_archive" : "libs/serialization/test/test_forward_list_ptrs.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_forward_list_ptrs_text_warchive" : "libs/serialization/test/test_forward_list_ptrs.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_forward_list_ptrs_binary_archive" : "libs/serialization/test/test_forward_list_ptrs.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_forward_list_ptrs_xml_archive" : "libs/serialization/test/test_forward_list_ptrs.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_forward_list_ptrs_xml_warchive" : "libs/serialization/test/test_forward_list_ptrs.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_helper_support_text_archive" : "libs/serialization/test/test_helper_support.cpp" +boost-test(RUN) "serialization/test_helper_support_text_warchive" : "libs/serialization/test/test_helper_support.cpp" +boost-test(RUN) "serialization/test_helper_support_binary_archive" : "libs/serialization/test/test_helper_support.cpp" +boost-test(RUN) "serialization/test_helper_support_xml_archive" : "libs/serialization/test/test_helper_support.cpp" +boost-test(RUN) "serialization/test_helper_support_xml_warchive" : "libs/serialization/test/test_helper_support.cpp" +boost-test(RUN) "serialization/test_interrupts_text_archive" : "libs/serialization/test/test_interrupts.cpp" +boost-test(RUN) "serialization/test_interrupts_text_warchive" : "libs/serialization/test/test_interrupts.cpp" +boost-test(RUN) "serialization/test_interrupts_binary_archive" : "libs/serialization/test/test_interrupts.cpp" +boost-test(RUN) "serialization/test_interrupts_xml_archive" : "libs/serialization/test/test_interrupts.cpp" +boost-test(RUN) "serialization/test_interrupts_xml_warchive" : "libs/serialization/test/test_interrupts.cpp" +boost-test(RUN) "serialization/test_list_text_archive" : "libs/serialization/test/test_list.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_list_text_warchive" : "libs/serialization/test/test_list.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_list_binary_archive" : "libs/serialization/test/test_list.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_list_xml_archive" : "libs/serialization/test/test_list.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_list_xml_warchive" : "libs/serialization/test/test_list.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_list_ptrs_text_archive" : "libs/serialization/test/test_list_ptrs.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_list_ptrs_text_warchive" : "libs/serialization/test/test_list_ptrs.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_list_ptrs_binary_archive" : "libs/serialization/test/test_list_ptrs.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_list_ptrs_xml_archive" : "libs/serialization/test/test_list_ptrs.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_list_ptrs_xml_warchive" : "libs/serialization/test/test_list_ptrs.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_map_text_archive" : "libs/serialization/test/test_map.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_map_text_warchive" : "libs/serialization/test/test_map.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_map_binary_archive" : "libs/serialization/test/test_map.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_map_xml_archive" : "libs/serialization/test/test_map.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_map_xml_warchive" : "libs/serialization/test/test_map.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_map_hashed_text_archive" : "libs/serialization/test/test_map_hashed.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_map_hashed_text_warchive" : "libs/serialization/test/test_map_hashed.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_map_hashed_binary_archive" : "libs/serialization/test/test_map_hashed.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_map_hashed_xml_archive" : "libs/serialization/test/test_map_hashed.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_map_hashed_xml_warchive" : "libs/serialization/test/test_map_hashed.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_map_unordered_text_archive" : "libs/serialization/test/test_map_unordered.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_map_unordered_text_warchive" : "libs/serialization/test/test_map_unordered.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_map_unordered_binary_archive" : "libs/serialization/test/test_map_unordered.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_map_unordered_xml_archive" : "libs/serialization/test/test_map_unordered.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_map_unordered_xml_warchive" : "libs/serialization/test/test_map_unordered.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_map_boost_unordered_text_archive" : "libs/serialization/test/test_map_boost_unordered.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_map_boost_unordered_text_warchive" : "libs/serialization/test/test_map_boost_unordered.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_map_boost_unordered_binary_archive" : "libs/serialization/test/test_map_boost_unordered.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_map_boost_unordered_xml_archive" : "libs/serialization/test/test_map_boost_unordered.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_map_boost_unordered_xml_warchive" : "libs/serialization/test/test_map_boost_unordered.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_mi_text_archive" : "libs/serialization/test/test_mi.cpp" +boost-test(RUN) "serialization/test_mi_text_warchive" : "libs/serialization/test/test_mi.cpp" +boost-test(RUN) "serialization/test_mi_binary_archive" : "libs/serialization/test/test_mi.cpp" +boost-test(RUN) "serialization/test_mi_xml_archive" : "libs/serialization/test/test_mi.cpp" +boost-test(RUN) "serialization/test_mi_xml_warchive" : "libs/serialization/test/test_mi.cpp" +boost-test(RUN) "serialization/test_multiple_ptrs_text_archive" : "libs/serialization/test/test_multiple_ptrs.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_multiple_ptrs_text_warchive" : "libs/serialization/test/test_multiple_ptrs.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_multiple_ptrs_binary_archive" : "libs/serialization/test/test_multiple_ptrs.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_multiple_ptrs_xml_archive" : "libs/serialization/test/test_multiple_ptrs.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_multiple_ptrs_xml_warchive" : "libs/serialization/test/test_multiple_ptrs.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_multiple_inheritance_text_archive" : "libs/serialization/test/test_multiple_inheritance.cpp" +boost-test(RUN) "serialization/test_multiple_inheritance_text_warchive" : "libs/serialization/test/test_multiple_inheritance.cpp" +boost-test(RUN) "serialization/test_multiple_inheritance_binary_archive" : "libs/serialization/test/test_multiple_inheritance.cpp" +boost-test(RUN) "serialization/test_multiple_inheritance_xml_archive" : "libs/serialization/test/test_multiple_inheritance.cpp" +boost-test(RUN) "serialization/test_multiple_inheritance_xml_warchive" : "libs/serialization/test/test_multiple_inheritance.cpp" +boost-test(RUN) "serialization/test_non_intrusive_text_archive" : "libs/serialization/test/test_non_intrusive.cpp" +boost-test(RUN) "serialization/test_non_intrusive_text_warchive" : "libs/serialization/test/test_non_intrusive.cpp" +boost-test(RUN) "serialization/test_non_intrusive_binary_archive" : "libs/serialization/test/test_non_intrusive.cpp" +boost-test(RUN) "serialization/test_non_intrusive_xml_archive" : "libs/serialization/test/test_non_intrusive.cpp" +boost-test(RUN) "serialization/test_non_intrusive_xml_warchive" : "libs/serialization/test/test_non_intrusive.cpp" +boost-test(RUN) "serialization/test_non_default_ctor_text_archive" : "libs/serialization/test/test_non_default_ctor.cpp" +boost-test(RUN) "serialization/test_non_default_ctor_text_warchive" : "libs/serialization/test/test_non_default_ctor.cpp" +boost-test(RUN) "serialization/test_non_default_ctor_binary_archive" : "libs/serialization/test/test_non_default_ctor.cpp" +boost-test(RUN) "serialization/test_non_default_ctor_xml_archive" : "libs/serialization/test/test_non_default_ctor.cpp" +boost-test(RUN) "serialization/test_non_default_ctor_xml_warchive" : "libs/serialization/test/test_non_default_ctor.cpp" +boost-test(RUN) "serialization/test_non_default_ctor2_text_archive" : "libs/serialization/test/test_non_default_ctor2.cpp" +boost-test(RUN) "serialization/test_non_default_ctor2_text_warchive" : "libs/serialization/test/test_non_default_ctor2.cpp" +boost-test(RUN) "serialization/test_non_default_ctor2_binary_archive" : "libs/serialization/test/test_non_default_ctor2.cpp" +boost-test(RUN) "serialization/test_non_default_ctor2_xml_archive" : "libs/serialization/test/test_non_default_ctor2.cpp" +boost-test(RUN) "serialization/test_non_default_ctor2_xml_warchive" : "libs/serialization/test/test_non_default_ctor2.cpp" +boost-test(RUN) "serialization/test_null_ptr_text_archive" : "libs/serialization/test/test_null_ptr.cpp" +boost-test(RUN) "serialization/test_null_ptr_text_warchive" : "libs/serialization/test/test_null_ptr.cpp" +boost-test(RUN) "serialization/test_null_ptr_binary_archive" : "libs/serialization/test/test_null_ptr.cpp" +boost-test(RUN) "serialization/test_null_ptr_xml_archive" : "libs/serialization/test/test_null_ptr.cpp" +boost-test(RUN) "serialization/test_null_ptr_xml_warchive" : "libs/serialization/test/test_null_ptr.cpp" +boost-test(RUN) "serialization/test_nvp_text_archive" : "libs/serialization/test/test_nvp.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_nvp_text_warchive" : "libs/serialization/test/test_nvp.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_nvp_binary_archive" : "libs/serialization/test/test_nvp.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_nvp_xml_archive" : "libs/serialization/test/test_nvp.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_nvp_xml_warchive" : "libs/serialization/test/test_nvp.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_object_text_archive" : "libs/serialization/test/test_object.cpp" +boost-test(RUN) "serialization/test_object_text_warchive" : "libs/serialization/test/test_object.cpp" +boost-test(RUN) "serialization/test_object_binary_archive" : "libs/serialization/test/test_object.cpp" +boost-test(RUN) "serialization/test_object_xml_archive" : "libs/serialization/test/test_object.cpp" +boost-test(RUN) "serialization/test_object_xml_warchive" : "libs/serialization/test/test_object.cpp" +boost-test(RUN) "serialization/test_primitive_text_archive" : "libs/serialization/test/test_primitive.cpp" +boost-test(RUN) "serialization/test_primitive_text_warchive" : "libs/serialization/test/test_primitive.cpp" +boost-test(RUN) "serialization/test_primitive_binary_archive" : "libs/serialization/test/test_primitive.cpp" +boost-test(RUN) "serialization/test_primitive_xml_archive" : "libs/serialization/test/test_primitive.cpp" +boost-test(RUN) "serialization/test_primitive_xml_warchive" : "libs/serialization/test/test_primitive.cpp" +boost-test(RUN) "serialization/test_priority_queue_text_archive" : "libs/serialization/test/test_priority_queue.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_priority_queue_text_warchive" : "libs/serialization/test/test_priority_queue.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_priority_queue_binary_archive" : "libs/serialization/test/test_priority_queue.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_priority_queue_xml_archive" : "libs/serialization/test/test_priority_queue.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_priority_queue_xml_warchive" : "libs/serialization/test/test_priority_queue.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_queue_text_archive" : "libs/serialization/test/test_queue.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_queue_text_warchive" : "libs/serialization/test/test_queue.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_queue_binary_archive" : "libs/serialization/test/test_queue.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_queue_xml_archive" : "libs/serialization/test/test_queue.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_queue_xml_warchive" : "libs/serialization/test/test_queue.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_recursion_text_archive" : "libs/serialization/test/test_recursion.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_recursion_text_warchive" : "libs/serialization/test/test_recursion.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_recursion_binary_archive" : "libs/serialization/test/test_recursion.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_recursion_xml_archive" : "libs/serialization/test/test_recursion.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_recursion_xml_warchive" : "libs/serialization/test/test_recursion.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_registered_text_archive" : "libs/serialization/test/test_registered.cpp" +boost-test(RUN) "serialization/test_registered_text_warchive" : "libs/serialization/test/test_registered.cpp" +boost-test(RUN) "serialization/test_registered_binary_archive" : "libs/serialization/test/test_registered.cpp" +boost-test(RUN) "serialization/test_registered_xml_archive" : "libs/serialization/test/test_registered.cpp" +boost-test(RUN) "serialization/test_registered_xml_warchive" : "libs/serialization/test/test_registered.cpp" +boost-test(RUN) "serialization/test_set_text_archive" : "libs/serialization/test/test_set.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_set_text_warchive" : "libs/serialization/test/test_set.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_set_binary_archive" : "libs/serialization/test/test_set.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_set_xml_archive" : "libs/serialization/test/test_set.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_set_xml_warchive" : "libs/serialization/test/test_set.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_set_hashed_text_archive" : "libs/serialization/test/test_set_hashed.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_set_hashed_text_warchive" : "libs/serialization/test/test_set_hashed.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_set_hashed_binary_archive" : "libs/serialization/test/test_set_hashed.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_set_hashed_xml_archive" : "libs/serialization/test/test_set_hashed.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_set_hashed_xml_warchive" : "libs/serialization/test/test_set_hashed.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_set_unordered_text_archive" : "libs/serialization/test/test_set_unordered.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_set_unordered_text_warchive" : "libs/serialization/test/test_set_unordered.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_set_unordered_binary_archive" : "libs/serialization/test/test_set_unordered.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_set_unordered_xml_archive" : "libs/serialization/test/test_set_unordered.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_set_unordered_xml_warchive" : "libs/serialization/test/test_set_unordered.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_set_boost_unordered_text_archive" : "libs/serialization/test/test_set_boost_unordered.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_set_boost_unordered_text_warchive" : "libs/serialization/test/test_set_boost_unordered.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_set_boost_unordered_binary_archive" : "libs/serialization/test/test_set_boost_unordered.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_set_boost_unordered_xml_archive" : "libs/serialization/test/test_set_boost_unordered.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_set_boost_unordered_xml_warchive" : "libs/serialization/test/test_set_boost_unordered.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_simple_class_text_archive" : "libs/serialization/test/test_simple_class.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_simple_class_text_warchive" : "libs/serialization/test/test_simple_class.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_simple_class_binary_archive" : "libs/serialization/test/test_simple_class.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_simple_class_xml_archive" : "libs/serialization/test/test_simple_class.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_simple_class_xml_warchive" : "libs/serialization/test/test_simple_class.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_simple_class_ptr_text_archive" : "libs/serialization/test/test_simple_class_ptr.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_simple_class_ptr_text_warchive" : "libs/serialization/test/test_simple_class_ptr.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_simple_class_ptr_binary_archive" : "libs/serialization/test/test_simple_class_ptr.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_simple_class_ptr_xml_archive" : "libs/serialization/test/test_simple_class_ptr.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_simple_class_ptr_xml_warchive" : "libs/serialization/test/test_simple_class_ptr.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_slist_text_archive" : "libs/serialization/test/test_slist.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_slist_text_warchive" : "libs/serialization/test/test_slist.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_slist_binary_archive" : "libs/serialization/test/test_slist.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_slist_xml_archive" : "libs/serialization/test/test_slist.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_slist_xml_warchive" : "libs/serialization/test/test_slist.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_slist_ptrs_text_archive" : "libs/serialization/test/test_slist_ptrs.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_slist_ptrs_text_warchive" : "libs/serialization/test/test_slist_ptrs.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_slist_ptrs_binary_archive" : "libs/serialization/test/test_slist_ptrs.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_slist_ptrs_xml_archive" : "libs/serialization/test/test_slist_ptrs.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_slist_ptrs_xml_warchive" : "libs/serialization/test/test_slist_ptrs.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_split_text_archive" : "libs/serialization/test/test_split.cpp" +boost-test(RUN) "serialization/test_split_text_warchive" : "libs/serialization/test/test_split.cpp" +boost-test(RUN) "serialization/test_split_binary_archive" : "libs/serialization/test/test_split.cpp" +boost-test(RUN) "serialization/test_split_xml_archive" : "libs/serialization/test/test_split.cpp" +boost-test(RUN) "serialization/test_split_xml_warchive" : "libs/serialization/test/test_split.cpp" +boost-test(RUN) "serialization/test_stack_text_archive" : "libs/serialization/test/test_stack.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_stack_text_warchive" : "libs/serialization/test/test_stack.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_stack_binary_archive" : "libs/serialization/test/test_stack.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_stack_xml_archive" : "libs/serialization/test/test_stack.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_stack_xml_warchive" : "libs/serialization/test/test_stack.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_tracking_text_archive" : "libs/serialization/test/test_tracking.cpp" +boost-test(RUN) "serialization/test_tracking_text_warchive" : "libs/serialization/test/test_tracking.cpp" +boost-test(RUN) "serialization/test_tracking_binary_archive" : "libs/serialization/test/test_tracking.cpp" +boost-test(RUN) "serialization/test_tracking_xml_archive" : "libs/serialization/test/test_tracking.cpp" +boost-test(RUN) "serialization/test_tracking_xml_warchive" : "libs/serialization/test/test_tracking.cpp" +boost-test(RUN) "serialization/test_unregistered_text_archive" : "libs/serialization/test/test_unregistered.cpp" +boost-test(RUN) "serialization/test_unregistered_text_warchive" : "libs/serialization/test/test_unregistered.cpp" +boost-test(RUN) "serialization/test_unregistered_binary_archive" : "libs/serialization/test/test_unregistered.cpp" +boost-test(RUN) "serialization/test_unregistered_xml_archive" : "libs/serialization/test/test_unregistered.cpp" +boost-test(RUN) "serialization/test_unregistered_xml_warchive" : "libs/serialization/test/test_unregistered.cpp" +boost-test(RUN) "serialization/test_unique_ptr_text_archive" : "libs/serialization/test/test_unique_ptr.cpp" +boost-test(RUN) "serialization/test_unique_ptr_text_warchive" : "libs/serialization/test/test_unique_ptr.cpp" +boost-test(RUN) "serialization/test_unique_ptr_binary_archive" : "libs/serialization/test/test_unique_ptr.cpp" +boost-test(RUN) "serialization/test_unique_ptr_xml_archive" : "libs/serialization/test/test_unique_ptr.cpp" +boost-test(RUN) "serialization/test_unique_ptr_xml_warchive" : "libs/serialization/test/test_unique_ptr.cpp" +boost-test(RUN) "serialization/test_valarray_text_archive" : "libs/serialization/test/test_valarray.cpp" +boost-test(RUN) "serialization/test_valarray_text_warchive" : "libs/serialization/test/test_valarray.cpp" +boost-test(RUN) "serialization/test_valarray_binary_archive" : "libs/serialization/test/test_valarray.cpp" +boost-test(RUN) "serialization/test_valarray_xml_archive" : "libs/serialization/test/test_valarray.cpp" +boost-test(RUN) "serialization/test_valarray_xml_warchive" : "libs/serialization/test/test_valarray.cpp" +boost-test(RUN) "serialization/test_variant_text_archive" : "libs/serialization/test/test_variant.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_variant_text_warchive" : "libs/serialization/test/test_variant.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_variant_binary_archive" : "libs/serialization/test/test_variant.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_variant_xml_archive" : "libs/serialization/test/test_variant.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_variant_xml_warchive" : "libs/serialization/test/test_variant.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_vector_text_archive" : "libs/serialization/test/test_vector.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_vector_text_warchive" : "libs/serialization/test/test_vector.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_vector_binary_archive" : "libs/serialization/test/test_vector.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_vector_xml_archive" : "libs/serialization/test/test_vector.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_vector_xml_warchive" : "libs/serialization/test/test_vector.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_new_operator_text_archive" : "libs/serialization/test/test_new_operator.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_new_operator_text_warchive" : "libs/serialization/test/test_new_operator.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_new_operator_binary_archive" : "libs/serialization/test/test_new_operator.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_new_operator_xml_archive" : "libs/serialization/test/test_new_operator.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_new_operator_xml_warchive" : "libs/serialization/test/test_new_operator.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_optional_text_archive" : "libs/serialization/test/test_optional.cpp" +boost-test(RUN) "serialization/test_optional_text_warchive" : "libs/serialization/test/test_optional.cpp" +boost-test(RUN) "serialization/test_optional_binary_archive" : "libs/serialization/test/test_optional.cpp" +boost-test(RUN) "serialization/test_optional_xml_archive" : "libs/serialization/test/test_optional.cpp" +boost-test(RUN) "serialization/test_optional_xml_warchive" : "libs/serialization/test/test_optional.cpp" +boost-test(RUN) "serialization/test_shared_ptr_text_archive" : "libs/serialization/test/test_shared_ptr.cpp" +boost-test(RUN) "serialization/test_shared_ptr_text_warchive" : "libs/serialization/test/test_shared_ptr.cpp" +boost-test(RUN) "serialization/test_shared_ptr_binary_archive" : "libs/serialization/test/test_shared_ptr.cpp" +boost-test(RUN) "serialization/test_shared_ptr_xml_archive" : "libs/serialization/test/test_shared_ptr.cpp" +boost-test(RUN) "serialization/test_shared_ptr_xml_warchive" : "libs/serialization/test/test_shared_ptr.cpp" +boost-test(RUN) "serialization/test_shared_ptr_multi_base_text_archive" : "libs/serialization/test/test_shared_ptr_multi_base.cpp" +boost-test(RUN) "serialization/test_shared_ptr_multi_base_text_warchive" : "libs/serialization/test/test_shared_ptr_multi_base.cpp" +boost-test(RUN) "serialization/test_shared_ptr_multi_base_binary_archive" : "libs/serialization/test/test_shared_ptr_multi_base.cpp" +boost-test(RUN) "serialization/test_shared_ptr_multi_base_xml_archive" : "libs/serialization/test/test_shared_ptr_multi_base.cpp" +boost-test(RUN) "serialization/test_shared_ptr_multi_base_xml_warchive" : "libs/serialization/test/test_shared_ptr_multi_base.cpp" +boost-test(RUN) "serialization/test_shared_ptr_132_text_archive" : "libs/serialization/test/test_shared_ptr_132.cpp" +boost-test(RUN) "serialization/test_shared_ptr_132_text_warchive" : "libs/serialization/test/test_shared_ptr_132.cpp" +boost-test(RUN) "serialization/test_shared_ptr_132_binary_archive" : "libs/serialization/test/test_shared_ptr_132.cpp" +boost-test(RUN) "serialization/test_shared_ptr_132_xml_archive" : "libs/serialization/test/test_shared_ptr_132.cpp" +boost-test(RUN) "serialization/test_shared_ptr_132_xml_warchive" : "libs/serialization/test/test_shared_ptr_132.cpp" +boost-test(RUN) "serialization/test_polymorphic_polymorphic_text_archive" : "libs/serialization/test/test_polymorphic.cpp" "libs/serialization/test/test_polymorphic_A.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_polymorphic_polymorphic_text_warchive" : "libs/serialization/test/test_polymorphic.cpp" "libs/serialization/test/test_polymorphic_A.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_polymorphic_polymorphic_binary_archive" : "libs/serialization/test/test_polymorphic.cpp" "libs/serialization/test/test_polymorphic_A.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_polymorphic_polymorphic_xml_archive" : "libs/serialization/test/test_polymorphic.cpp" "libs/serialization/test/test_polymorphic_A.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_polymorphic_polymorphic_xml_warchive" : "libs/serialization/test/test_polymorphic.cpp" "libs/serialization/test/test_polymorphic_A.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_polymorphic2_polymorphic_text_archive" : "libs/serialization/test/test_polymorphic2.cpp" "libs/serialization/test/test_polymorphic2imp.cpp" +boost-test(RUN) "serialization/test_polymorphic2_polymorphic_text_warchive" : "libs/serialization/test/test_polymorphic2.cpp" "libs/serialization/test/test_polymorphic2imp.cpp" +boost-test(RUN) "serialization/test_polymorphic2_polymorphic_binary_archive" : "libs/serialization/test/test_polymorphic2.cpp" "libs/serialization/test/test_polymorphic2imp.cpp" +boost-test(RUN) "serialization/test_polymorphic2_polymorphic_xml_archive" : "libs/serialization/test/test_polymorphic2.cpp" "libs/serialization/test/test_polymorphic2imp.cpp" +boost-test(RUN) "serialization/test_polymorphic2_polymorphic_xml_warchive" : "libs/serialization/test/test_polymorphic2.cpp" "libs/serialization/test/test_polymorphic2imp.cpp" +boost-test(RUN) "serialization/test_p_helper_polymorphic_text_archive" : "libs/serialization/test/test_p_helper.cpp" +boost-test(RUN) "serialization/test_p_helper_polymorphic_text_warchive" : "libs/serialization/test/test_p_helper.cpp" +boost-test(RUN) "serialization/test_p_helper_polymorphic_binary_archive" : "libs/serialization/test/test_p_helper.cpp" +boost-test(RUN) "serialization/test_p_helper_polymorphic_xml_archive" : "libs/serialization/test/test_p_helper.cpp" +boost-test(RUN) "serialization/test_p_helper_polymorphic_xml_warchive" : "libs/serialization/test/test_p_helper.cpp" +boost-test(RUN) "serialization/test_dll_exported_polymorphic_text_archive" : "libs/serialization/test/test_dll_exported.cpp" "libs/serialization/test/polymorphic_derived1.cpp" +boost-test(RUN) "serialization/test_dll_exported_polymorphic_text_warchive" : "libs/serialization/test/test_dll_exported.cpp" "libs/serialization/test/polymorphic_derived1.cpp" +boost-test(RUN) "serialization/test_dll_exported_polymorphic_binary_archive" : "libs/serialization/test/test_dll_exported.cpp" "libs/serialization/test/polymorphic_derived1.cpp" +boost-test(RUN) "serialization/test_dll_exported_polymorphic_xml_archive" : "libs/serialization/test/test_dll_exported.cpp" "libs/serialization/test/polymorphic_derived1.cpp" +boost-test(RUN) "serialization/test_dll_exported_polymorphic_xml_warchive" : "libs/serialization/test/test_dll_exported.cpp" "libs/serialization/test/polymorphic_derived1.cpp" +boost-test(RUN) "serialization/test_no_rtti_polymorphic_text_archive" : "libs/serialization/test/test_no_rtti.cpp" "libs/serialization/test/polymorphic_base.cpp" "libs/serialization/test/polymorphic_derived1.cpp" "libs/serialization/test/polymorphic_derived2.cpp" +boost-test(RUN) "serialization/test_no_rtti_polymorphic_text_warchive" : "libs/serialization/test/test_no_rtti.cpp" "libs/serialization/test/polymorphic_base.cpp" "libs/serialization/test/polymorphic_derived1.cpp" "libs/serialization/test/polymorphic_derived2.cpp" +boost-test(RUN) "serialization/test_no_rtti_polymorphic_binary_archive" : "libs/serialization/test/test_no_rtti.cpp" "libs/serialization/test/polymorphic_base.cpp" "libs/serialization/test/polymorphic_derived1.cpp" "libs/serialization/test/polymorphic_derived2.cpp" +boost-test(RUN) "serialization/test_no_rtti_polymorphic_xml_archive" : "libs/serialization/test/test_no_rtti.cpp" "libs/serialization/test/polymorphic_base.cpp" "libs/serialization/test/polymorphic_derived1.cpp" "libs/serialization/test/polymorphic_derived2.cpp" +boost-test(RUN) "serialization/test_no_rtti_polymorphic_xml_warchive" : "libs/serialization/test/test_no_rtti.cpp" "libs/serialization/test/polymorphic_base.cpp" "libs/serialization/test/polymorphic_derived1.cpp" "libs/serialization/test/polymorphic_derived2.cpp" +boost-test(RUN) "serialization/test_exported_polymorphic_text_archive" : "libs/serialization/test/test_exported.cpp" "libs/serialization/test/polymorphic_base.cpp" "libs/serialization/test/polymorphic_derived1.cpp" "libs/serialization/test/polymorphic_derived2.cpp" +boost-test(RUN) "serialization/test_exported_polymorphic_text_warchive" : "libs/serialization/test/test_exported.cpp" "libs/serialization/test/polymorphic_base.cpp" "libs/serialization/test/polymorphic_derived1.cpp" "libs/serialization/test/polymorphic_derived2.cpp" +boost-test(RUN) "serialization/test_exported_polymorphic_binary_archive" : "libs/serialization/test/test_exported.cpp" "libs/serialization/test/polymorphic_base.cpp" "libs/serialization/test/polymorphic_derived1.cpp" "libs/serialization/test/polymorphic_derived2.cpp" +boost-test(RUN) "serialization/test_exported_polymorphic_xml_archive" : "libs/serialization/test/test_exported.cpp" "libs/serialization/test/polymorphic_base.cpp" "libs/serialization/test/polymorphic_derived1.cpp" "libs/serialization/test/polymorphic_derived2.cpp" +boost-test(RUN) "serialization/test_exported_polymorphic_xml_warchive" : "libs/serialization/test/test_exported.cpp" "libs/serialization/test/polymorphic_base.cpp" "libs/serialization/test/polymorphic_derived1.cpp" "libs/serialization/test/polymorphic_derived2.cpp" +boost-test(COMPILE) "serialization/test_strong_typedef" : "libs/serialization/test/test_strong_typedef.cpp" +boost-test(RUN) "serialization/test_inclusion" : "libs/serialization/test/test_inclusion.cpp" +boost-test(RUN) "serialization/test_inclusion2" : "libs/serialization/test/test_inclusion2.cpp" +boost-test(RUN) "serialization/test_dll_simple" : "libs/serialization/test/test_dll_simple.cpp" +boost-test(RUN) "serialization/test_private_ctor" : "libs/serialization/test/test_private_ctor.cpp" +boost-test(RUN) "serialization/test_reset_object_address" : "libs/serialization/test/test_reset_object_address.cpp" "libs/serialization/test/A.cpp" +boost-test(RUN) "serialization/test_void_cast" : "libs/serialization/test/test_void_cast.cpp" +boost-test(RUN) "serialization/test_mult_archive_types" : "libs/serialization/test/test_mult_archive_types.cpp" +boost-test(RUN) "serialization/test_iterators" : "libs/serialization/test/test_iterators.cpp" +boost-test(RUN) "serialization/test_iterators_base64" : "libs/serialization/test/test_iterators_base64.cpp" +boost-test(RUN) "serialization/test_smart_cast" : "libs/serialization/test/test_smart_cast.cpp" +boost-test(RUN) "serialization/test_codecvt_null" : "libs/serialization/test/test_codecvt_null.cpp" +boost-test(RUN) "serialization/test_singleton" : "libs/serialization/test/test_singleton.cpp" +boost-test(RUN) "serialization/test_singleton_inherited" : "libs/serialization/test/test_singleton_inherited.cpp" +boost-test(RUN) "serialization/test_singleton_plain" : "libs/serialization/test/test_singleton_plain.cpp" +boost-test(COMPILE_FAIL) "serialization/test_not_serializable" : "libs/serialization/test/test_not_serializable.cpp" +boost-test(COMPILE_FAIL) "serialization/test_traits_fail" : "libs/serialization/test/test_traits_fail.cpp" +boost-test(COMPILE_FAIL) "serialization/test_const_load_fail1" : "libs/serialization/test/test_const_load_fail1.cpp" +boost-test(COMPILE_FAIL) "serialization/test_const_load_fail2" : "libs/serialization/test/test_const_load_fail2.cpp" +boost-test(COMPILE_FAIL) "serialization/test_const_load_fail3" : "libs/serialization/test/test_const_load_fail3.cpp" +boost-test(COMPILE_FAIL) "serialization/test_const_load_fail1_nvp" : "libs/serialization/test/test_const_load_fail1_nvp.cpp" +boost-test(COMPILE_FAIL) "serialization/test_const_load_fail2_nvp" : "libs/serialization/test/test_const_load_fail2_nvp.cpp" +boost-test(COMPILE_FAIL) "serialization/test_const_load_fail3_nvp" : "libs/serialization/test/test_const_load_fail3_nvp.cpp" +boost-test(COMPILE_FAIL) "serialization/test_check" : "libs/serialization/test/test_check.cpp" +boost-test(COMPILE) "serialization/test_static_warning" : "libs/serialization/test/test_static_warning.cpp" +boost-test(COMPILE) "serialization/test_const_save_warn1" : "libs/serialization/test/test_const_save_warn1.cpp" +boost-test(COMPILE) "serialization/test_const_save_warn2" : "libs/serialization/test/test_const_save_warn2.cpp" +boost-test(COMPILE) "serialization/test_const_save_warn3" : "libs/serialization/test/test_const_save_warn3.cpp" +boost-test(COMPILE) "serialization/test_traits_pass" : "libs/serialization/test/test_traits_pass.cpp" +boost-test(COMPILE) "serialization/test_const_pass" : "libs/serialization/test/test_const_pass.cpp" +...patience... +...patience... +...found 6867 targets... +...updating 1433 targets... +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/build/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_iarchive.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/build/clang-darwin-03/debug/threading-multi/visibility-hidden/binary_oarchive.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/build/clang-darwin-03/debug/threading-multi/visibility-hidden/binary_iarchive.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/build/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_oarchive.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/build/clang-darwin-03/debug/threading-multi/visibility-hidden/text_iarchive.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/build/clang-darwin-03/debug/threading-multi/visibility-hidden/text_oarchive.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_array_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_array.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/build/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_text_iarchive.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/build/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_text_oarchive.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/build/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_binary_iarchive.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/build/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_binary_oarchive.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/build/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_xml_iarchive.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/build/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_xml_oarchive.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/build/clang-darwin-03/debug/threading-multi/visibility-hidden/xml_oarchive.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/build/clang-darwin-03/debug/threading-multi/visibility-hidden/xml_iarchive.o +clang-darwin.link.dll ../../../bin.v2/libs/serialization/build/clang-darwin-03/debug/threading-multi/visibility-hidden/libboost_serialization.dylib +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_array_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_array_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_array_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_array_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_array_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_array_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/build/clang-darwin-03/debug/threading-multi/visibility-hidden/text_wiarchive.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/build/clang-darwin-03/debug/threading-multi/visibility-hidden/text_woarchive.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_array_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_array.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/build/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_text_wiarchive.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/build/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_text_woarchive.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/build/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_xml_wiarchive.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/build/clang-darwin-03/debug/threading-multi/visibility-hidden/xml_woarchive.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/build/clang-darwin-03/debug/threading-multi/visibility-hidden/xml_wiarchive.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/build/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_xml_woarchive.o +clang-darwin.link.dll ../../../bin.v2/libs/serialization/build/clang-darwin-03/debug/threading-multi/visibility-hidden/libboost_wserialization.dylib +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_array_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_array_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_array_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_array_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_array_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_array_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_array_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_array.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_array_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_array.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_array_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_array_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_array_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_array_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_array_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_array_xml_archive.test +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_array_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_array_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_array_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_array_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_array_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_array_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_array_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_array.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_array_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_array_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_array_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_array_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_array_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_array_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_boost_array_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_boost_array.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_boost_array_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_boost_array_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_boost_array_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_boost_array_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_boost_array_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_boost_array_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_boost_array_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_boost_array.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_boost_array_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_boost_array.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_boost_array_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_boost_array_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_boost_array_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_boost_array_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_boost_array_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_boost_array_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_boost_array_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_boost_array.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_boost_array_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_boost_array_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_boost_array_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_boost_array_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_boost_array_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_boost_array_text_warchive.test +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_boost_array_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_boost_array_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_boost_array_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_boost_array_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_boost_array_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_boost_array_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_boost_array_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_boost_array.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_boost_array_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_boost_array_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_boost_array_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_boost_array_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_boost_array_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_boost_array_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_native_array_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_native_array.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_native_array_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_native_array_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_native_array_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_native_array_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_native_array_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_native_array_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_native_array_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_native_array.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_native_array_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_native_array.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_native_array_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_native_array_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_native_array_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_native_array_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_native_array_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_native_array_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_native_array_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_native_array.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_native_array_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_native_array_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_native_array_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_native_array_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_native_array_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_native_array_xml_archive.test +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_native_array_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_native_array_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_native_array_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_native_array_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_native_array_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_native_array_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_binary_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_binary.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_binary_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_binary_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_binary_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_binary_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_binary_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_binary_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_binary_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_binary.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_binary_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_binary_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_binary_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_binary_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_binary_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_binary_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_binary_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_binary.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_native_array_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_native_array.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_binary_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_binary_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_binary_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_binary_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_binary_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_binary_binary_archive.test +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_native_array_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_native_array_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_native_array_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_native_array_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_native_array_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_native_array_xml_warchive.test +...on 100th target... +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_binary_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_binary.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_binary_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_binary_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_binary_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_binary_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_binary_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_binary_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_binary_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_binary.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_binary_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_binary_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_binary_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_binary_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_binary_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_binary_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_class_info_save_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_class_info_save.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_class_info_save_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_class_info_save_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_class_info_save_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_class_info_save_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_class_info_save_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_class_info_save_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_class_info_save_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_class_info_save.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_class_info_save_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_class_info_save_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_class_info_save_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_class_info_save_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_class_info_save_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_class_info_save_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_class_info_save_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_class_info_save.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_class_info_save_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_class_info_save_binary_archive +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_class_info_save_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_class_info_save.o +testing.capture-output ../../../bin.v2/libs/serialization/test/test_class_info_save_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_class_info_save_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_class_info_save_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_class_info_save_binary_archive.test +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_class_info_save_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_class_info_save_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_class_info_save_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_class_info_save_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_class_info_save_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_class_info_save_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_class_info_save_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_class_info_save.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_class_info_save_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_class_info_save_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_class_info_save_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_class_info_save_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_class_info_save_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_class_info_save_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_class_info_load_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_class_info_load.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_class_info_load_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_class_info_load_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_class_info_load_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_class_info_load_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_class_info_load_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_class_info_load_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_class_info_load_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_class_info_load.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_class_info_load_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_class_info_load_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_class_info_load_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_class_info_load_text_warchive.run +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_class_info_load_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_class_info_load.o +**passed** ../../../bin.v2/libs/serialization/test/test_class_info_load_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_class_info_load_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_class_info_load_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_class_info_load.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_class_info_load_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_class_info_load_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_class_info_load_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_class_info_load_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_class_info_load_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_class_info_load_binary_archive.test +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_class_info_load_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_class_info_load_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_class_info_load_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_class_info_load_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_class_info_load_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_class_info_load_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_class_info_load_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_class_info_load.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_class_info_load_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_class_info_load_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_class_info_load_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_class_info_load_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_class_info_load_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_class_info_load_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_bitset_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_bitset.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_bitset_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_bitset.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_bitset_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_bitset_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_bitset_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_bitset_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_bitset_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_bitset_text_archive.test +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_bitset_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_bitset_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_bitset_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_bitset_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_bitset_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_bitset_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_bitset_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_bitset.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_bitset_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_bitset_binary_archive +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_bitset_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_bitset.o +testing.capture-output ../../../bin.v2/libs/serialization/test/test_bitset_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_bitset_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_bitset_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_bitset_binary_archive.test +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_bitset_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_bitset_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_bitset_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_bitset_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_bitset_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_bitset_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_bitset_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_bitset.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_bitset_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_bitset_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_bitset_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_bitset_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_bitset_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_bitset_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_complex_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_complex.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_complex_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_complex_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_complex_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_complex_text_archive.run +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_complex_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_complex.o +**passed** ../../../bin.v2/libs/serialization/test/test_complex_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_complex_text_archive.test +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_complex_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_complex_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_complex_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_complex_text_warchive.run +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_complex_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_complex.o +**passed** ../../../bin.v2/libs/serialization/test/test_complex_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_complex_text_warchive.test +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_complex_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_complex_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_complex_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_complex_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_complex_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_complex_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_complex_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_complex.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_complex_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_complex_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_complex_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_complex_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_complex_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_complex_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_complex_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_complex.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_complex_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_complex_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_complex_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_complex_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_complex_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_complex_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_contained_class_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_contained_class.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_contained_class_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_contained_class.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_contained_class_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_contained_class_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_contained_class_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_contained_class_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_contained_class_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_contained_class_text_archive.test +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_contained_class_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_contained_class_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_contained_class_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_contained_class_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_contained_class_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_contained_class_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_contained_class_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_contained_class.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_contained_class_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_contained_class_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_contained_class_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_contained_class_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_contained_class_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_contained_class_binary_archive.test +...on 200th target... +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_contained_class_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_contained_class.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_contained_class_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_contained_class_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_contained_class_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_contained_class_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_contained_class_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_contained_class_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_contained_class_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_contained_class.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_contained_class_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_contained_class_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_contained_class_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_contained_class_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_contained_class_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_contained_class_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_cyclic_ptrs_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_cyclic_ptrs.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_cyclic_ptrs_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_cyclic_ptrs_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_cyclic_ptrs_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_cyclic_ptrs_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_cyclic_ptrs_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_cyclic_ptrs_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_cyclic_ptrs_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_cyclic_ptrs.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_cyclic_ptrs_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_cyclic_ptrs_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_cyclic_ptrs_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_cyclic_ptrs_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_cyclic_ptrs_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_cyclic_ptrs_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_cyclic_ptrs_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_cyclic_ptrs.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_cyclic_ptrs_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_cyclic_ptrs_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_cyclic_ptrs_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_cyclic_ptrs_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_cyclic_ptrs_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_cyclic_ptrs_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_cyclic_ptrs_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_cyclic_ptrs.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_cyclic_ptrs_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_cyclic_ptrs_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_cyclic_ptrs_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_cyclic_ptrs_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_cyclic_ptrs_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_cyclic_ptrs_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_cyclic_ptrs_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_cyclic_ptrs.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_cyclic_ptrs_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_cyclic_ptrs_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_cyclic_ptrs_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_cyclic_ptrs_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_cyclic_ptrs_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_cyclic_ptrs_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_delete_pointer_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_delete_pointer.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_delete_pointer_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_delete_pointer_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_delete_pointer_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_delete_pointer_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_delete_pointer_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_delete_pointer_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_delete_pointer_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_delete_pointer.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_delete_pointer_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_delete_pointer_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_delete_pointer_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_delete_pointer_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_delete_pointer_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_delete_pointer_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_delete_pointer_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_delete_pointer.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_delete_pointer_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_delete_pointer.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_delete_pointer_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_delete_pointer_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_delete_pointer_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_delete_pointer_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_delete_pointer_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_delete_pointer_xml_archive.test +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_delete_pointer_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_delete_pointer_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_delete_pointer_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_delete_pointer_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_delete_pointer_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_delete_pointer_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_delete_pointer_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_delete_pointer.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_delete_pointer_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_delete_pointer_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_delete_pointer_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_delete_pointer_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_delete_pointer_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_delete_pointer_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_deque_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_deque.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_deque_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_deque_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_deque_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_deque_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_deque_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_deque_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_deque_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_deque.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_deque_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_deque_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_deque_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_deque_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_deque_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_deque_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_deque_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_deque.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_deque_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_deque_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_deque_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_deque_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_deque_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_deque_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_deque_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_deque.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_deque_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_deque_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_deque_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_deque_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_deque_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_deque_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_deque_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_deque.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_deque_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_deque_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_deque_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_deque_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_deque_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_deque_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_derived_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_derived_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_derived_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_derived_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_derived_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_derived_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_derived_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_derived_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_derived_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_derived_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_derived_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_derived_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_derived_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_derived_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_derived_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_derived_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_derived_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_derived_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_derived_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_derived_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_derived_class_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_class.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_derived_class_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_class_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_derived_class_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_class_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_derived_class_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_class_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_derived_class_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_class.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_derived_class_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_class_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_derived_class_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_class_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_derived_class_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_class_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_derived_class_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_class.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_derived_class_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_class.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_derived_class_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_class_xml_archive +...on 300th target... +testing.capture-output ../../../bin.v2/libs/serialization/test/test_derived_class_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_class_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_derived_class_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_class_xml_archive.test +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_derived_class_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_class_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_derived_class_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_class_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_derived_class_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_class_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_derived_class_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_class.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_derived_class_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_class_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_derived_class_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_class_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_derived_class_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_class_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_derived_class_ptr_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_class_ptr.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_derived_class_ptr_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_class_ptr_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_derived_class_ptr_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_class_ptr_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_derived_class_ptr_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_class_ptr_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_derived_class_ptr_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_class_ptr.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_derived_class_ptr_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_class_ptr_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_derived_class_ptr_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_class_ptr_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_derived_class_ptr_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_class_ptr_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_derived_class_ptr_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_class_ptr.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_derived_class_ptr_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_class_ptr_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_derived_class_ptr_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_class_ptr_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_derived_class_ptr_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_class_ptr_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_derived_class_ptr_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_class_ptr.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_derived_class_ptr_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_class_ptr_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_derived_class_ptr_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_class_ptr_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_derived_class_ptr_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_class_ptr_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_derived_class_ptr_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_class_ptr.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_derived_class_ptr_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_class_ptr_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_derived_class_ptr_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_class_ptr_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_derived_class_ptr_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_derived_class_ptr_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_diamond_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_diamond.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_diamond_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_diamond_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_diamond_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_diamond_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_diamond_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_diamond_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_diamond_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_diamond.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_diamond_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_diamond_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_diamond_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_diamond_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_diamond_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_diamond_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_diamond_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_diamond.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_diamond_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_diamond_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_diamond_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_diamond_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_diamond_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_diamond_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_diamond_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_diamond.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_diamond_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_diamond_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_diamond_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_diamond_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_diamond_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_diamond_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_diamond_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_diamond.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_diamond_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_diamond_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_diamond_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_diamond_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_diamond_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_diamond_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_diamond_complex_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_diamond_complex.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_diamond_complex_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_diamond_complex_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_diamond_complex_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_diamond_complex_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_diamond_complex_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_diamond_complex_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_diamond_complex_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_diamond_complex.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_diamond_complex_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_diamond_complex_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_diamond_complex_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_diamond_complex_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_diamond_complex_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_diamond_complex_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_diamond_complex_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_diamond_complex.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_diamond_complex_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_diamond_complex_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_diamond_complex_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_diamond_complex_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_diamond_complex_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_diamond_complex_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_diamond_complex_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_diamond_complex.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_diamond_complex_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_diamond_complex_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_diamond_complex_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_diamond_complex_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_diamond_complex_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_diamond_complex_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_forward_list_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_forward_list.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_forward_list_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_forward_list_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_forward_list_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_forward_list_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_forward_list_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_forward_list_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_diamond_complex_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_diamond_complex.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_diamond_complex_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_diamond_complex_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_diamond_complex_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_diamond_complex_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_diamond_complex_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_diamond_complex_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_forward_list_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_forward_list.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_forward_list_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_forward_list_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_forward_list_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_forward_list_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_forward_list_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_forward_list_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_forward_list_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_forward_list.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_forward_list_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_forward_list_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_forward_list_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_forward_list_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_forward_list_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_forward_list_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_forward_list_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_forward_list.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_forward_list_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_forward_list_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_forward_list_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_forward_list_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_forward_list_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_forward_list_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_forward_list_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_forward_list.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_forward_list_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_forward_list_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_forward_list_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_forward_list_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_forward_list_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_forward_list_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_forward_list_ptrs_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_forward_list_ptrs.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_forward_list_ptrs_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_forward_list_ptrs_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_forward_list_ptrs_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_forward_list_ptrs_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_forward_list_ptrs_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_forward_list_ptrs_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_forward_list_ptrs_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_forward_list_ptrs.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_forward_list_ptrs_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_forward_list_ptrs_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_forward_list_ptrs_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_forward_list_ptrs_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_forward_list_ptrs_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_forward_list_ptrs_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_forward_list_ptrs_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_forward_list_ptrs.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_forward_list_ptrs_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_forward_list_ptrs_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_forward_list_ptrs_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_forward_list_ptrs_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_forward_list_ptrs_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_forward_list_ptrs_xml_archive.test +...on 400th target... +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_forward_list_ptrs_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_forward_list_ptrs.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_forward_list_ptrs_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_forward_list_ptrs_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_forward_list_ptrs_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_forward_list_ptrs_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_forward_list_ptrs_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_forward_list_ptrs_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_forward_list_ptrs_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_forward_list_ptrs.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_forward_list_ptrs_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_forward_list_ptrs_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_forward_list_ptrs_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_forward_list_ptrs_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_forward_list_ptrs_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_forward_list_ptrs_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_helper_support_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_helper_support.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_helper_support_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_helper_support_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_helper_support_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_helper_support_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_helper_support_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_helper_support_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_helper_support_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_helper_support.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_helper_support_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_helper_support_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_helper_support_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_helper_support_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_helper_support_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_helper_support_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_helper_support_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_helper_support.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_helper_support_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_helper_support_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_helper_support_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_helper_support_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_helper_support_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_helper_support_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_helper_support_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_helper_support.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_helper_support_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_helper_support_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_helper_support_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_helper_support_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_helper_support_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_helper_support_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_interrupts_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_interrupts.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_interrupts_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_interrupts_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_interrupts_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_interrupts_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_interrupts_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_interrupts_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_helper_support_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_helper_support.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_interrupts_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_interrupts.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_helper_support_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_helper_support_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_helper_support_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_helper_support_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_helper_support_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_helper_support_xml_warchive.test +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_interrupts_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_interrupts_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_interrupts_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_interrupts_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_interrupts_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_interrupts_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_interrupts_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_interrupts.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_interrupts_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_interrupts_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_interrupts_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_interrupts_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_interrupts_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_interrupts_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_interrupts_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_interrupts.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_interrupts_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_interrupts_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_interrupts_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_interrupts_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_interrupts_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_interrupts_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_interrupts_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_interrupts.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_interrupts_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_interrupts_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_interrupts_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_interrupts_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_interrupts_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_interrupts_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_list_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_list.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_list_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_list_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_list_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_list_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_list_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_list_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_list_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_list.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_list_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_list_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_list_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_list_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_list_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_list_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_list_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_list.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_list_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_list_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_list_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_list_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_list_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_list_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_list_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_list.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_list_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_list_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_list_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_list_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_list_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_list_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_list_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_list.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_list_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_list_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_list_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_list_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_list_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_list_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_list_ptrs_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_list_ptrs.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_list_ptrs_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_list_ptrs_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_list_ptrs_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_list_ptrs_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_list_ptrs_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_list_ptrs_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_list_ptrs_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_list_ptrs.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_list_ptrs_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_list_ptrs_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_list_ptrs_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_list_ptrs_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_list_ptrs_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_list_ptrs_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_list_ptrs_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_list_ptrs.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_list_ptrs_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_list_ptrs_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_list_ptrs_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_list_ptrs_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_list_ptrs_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_list_ptrs_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_list_ptrs_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_list_ptrs.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_list_ptrs_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_list_ptrs_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_list_ptrs_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_list_ptrs_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_list_ptrs_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_list_ptrs_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_list_ptrs_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_list_ptrs.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_list_ptrs_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_list_ptrs_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_list_ptrs_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_list_ptrs_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_list_ptrs_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_list_ptrs_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_map_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_map.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_map_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_map_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_map_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_map_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_map_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_map_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_map_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_map.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_map_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_map_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_map_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_map_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_map_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_map_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_map_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_map.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_map_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_map_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_map_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_map_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_map_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_map_binary_archive.test +...on 500th target... +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_map_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_map.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_map_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_map_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_map_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_map_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_map_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_map_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_map_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_map.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_map_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_map_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_map_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_map_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_map_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_map_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_map_boost_unordered_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_map_boost_unordered.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_map_boost_unordered_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_map_boost_unordered_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_map_boost_unordered_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_map_boost_unordered_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_map_boost_unordered_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_map_boost_unordered_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_map_boost_unordered_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_map_boost_unordered.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_map_boost_unordered_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_map_boost_unordered_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_map_boost_unordered_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_map_boost_unordered_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_map_boost_unordered_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_map_boost_unordered_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_map_boost_unordered_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_map_boost_unordered.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_map_boost_unordered_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_map_boost_unordered_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_map_boost_unordered_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_map_boost_unordered_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_map_boost_unordered_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_map_boost_unordered_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_map_boost_unordered_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_map_boost_unordered.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_map_boost_unordered_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_map_boost_unordered_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_map_boost_unordered_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_map_boost_unordered_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_map_boost_unordered_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_map_boost_unordered_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_mi_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_mi.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_mi_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_mi_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_mi_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_mi_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_mi_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_mi_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_map_boost_unordered_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_map_boost_unordered.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_map_boost_unordered_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_map_boost_unordered_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_map_boost_unordered_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_map_boost_unordered_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_map_boost_unordered_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_map_boost_unordered_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_mi_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_mi.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_mi_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_mi_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_mi_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_mi_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_mi_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_mi_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_mi_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_mi.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_mi_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_mi.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_mi_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_mi_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_mi_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_mi_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_mi_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_mi_binary_archive.test +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_mi_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_mi_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_mi_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_mi_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_mi_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_mi_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_mi_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_mi.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_mi_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_mi_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_mi_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_mi_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_mi_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_mi_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_multiple_ptrs_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_multiple_ptrs.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_multiple_ptrs_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_multiple_ptrs_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_multiple_ptrs_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_multiple_ptrs_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_multiple_ptrs_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_multiple_ptrs_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_multiple_ptrs_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_multiple_ptrs.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_multiple_ptrs_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_multiple_ptrs.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_multiple_ptrs_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_multiple_ptrs_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_multiple_ptrs_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_multiple_ptrs_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_multiple_ptrs_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_multiple_ptrs_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_multiple_ptrs_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_multiple_ptrs.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_multiple_ptrs_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_multiple_ptrs_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_multiple_ptrs_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_multiple_ptrs_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_multiple_ptrs_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_multiple_ptrs_xml_archive.test +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_multiple_ptrs_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_multiple_ptrs_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_multiple_ptrs_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_multiple_ptrs_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_multiple_ptrs_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_multiple_ptrs_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_multiple_ptrs_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_multiple_ptrs.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_multiple_ptrs_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_multiple_ptrs_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_multiple_ptrs_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_multiple_ptrs_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_multiple_ptrs_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_multiple_ptrs_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_multiple_inheritance_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_multiple_inheritance.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_multiple_inheritance_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_multiple_inheritance_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_multiple_inheritance_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_multiple_inheritance_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_multiple_inheritance_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_multiple_inheritance_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_multiple_inheritance_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_multiple_inheritance.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_multiple_inheritance_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_multiple_inheritance_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_multiple_inheritance_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_multiple_inheritance_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_multiple_inheritance_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_multiple_inheritance_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_multiple_inheritance_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_multiple_inheritance.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_multiple_inheritance_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_multiple_inheritance_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_multiple_inheritance_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_multiple_inheritance_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_multiple_inheritance_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_multiple_inheritance_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_multiple_inheritance_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_multiple_inheritance.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_multiple_inheritance_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_multiple_inheritance_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_multiple_inheritance_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_multiple_inheritance_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_multiple_inheritance_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_multiple_inheritance_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_multiple_inheritance_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_multiple_inheritance.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_multiple_inheritance_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_multiple_inheritance_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_multiple_inheritance_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_multiple_inheritance_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_multiple_inheritance_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_multiple_inheritance_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_non_intrusive_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_intrusive.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_non_intrusive_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_intrusive_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_non_intrusive_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_intrusive_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_non_intrusive_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_intrusive_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_non_intrusive_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_intrusive.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_non_intrusive_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_intrusive_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_non_intrusive_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_intrusive_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_non_intrusive_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_intrusive_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_non_intrusive_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_intrusive.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_non_intrusive_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_intrusive_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_non_intrusive_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_intrusive_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_non_intrusive_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_intrusive_binary_archive.test +...on 600th target... +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_non_intrusive_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_intrusive.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_non_intrusive_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_intrusive_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_non_intrusive_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_intrusive_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_non_intrusive_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_intrusive_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_non_intrusive_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_intrusive.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_non_intrusive_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_intrusive_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_non_intrusive_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_intrusive_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_non_intrusive_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_intrusive_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_non_default_ctor_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_default_ctor.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_non_default_ctor_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_default_ctor_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_non_default_ctor_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_default_ctor_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_non_default_ctor_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_default_ctor_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_non_default_ctor_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_default_ctor.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_non_default_ctor_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_default_ctor_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_non_default_ctor_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_default_ctor_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_non_default_ctor_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_default_ctor_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_non_default_ctor_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_default_ctor.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_non_default_ctor_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_default_ctor_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_non_default_ctor_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_default_ctor_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_non_default_ctor_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_default_ctor_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_non_default_ctor_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_default_ctor.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_non_default_ctor_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_default_ctor_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_non_default_ctor_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_default_ctor_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_non_default_ctor_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_default_ctor_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_non_default_ctor_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_default_ctor.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_non_default_ctor_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_default_ctor_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_non_default_ctor_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_default_ctor_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_non_default_ctor_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_default_ctor_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_non_default_ctor2_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_default_ctor2.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_non_default_ctor2_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_default_ctor2_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_non_default_ctor2_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_default_ctor2_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_non_default_ctor2_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_default_ctor2_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_non_default_ctor2_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_default_ctor2.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_non_default_ctor2_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_default_ctor2_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_non_default_ctor2_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_default_ctor2_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_non_default_ctor2_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_default_ctor2_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_non_default_ctor2_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_default_ctor2.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_non_default_ctor2_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_default_ctor2_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_non_default_ctor2_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_default_ctor2_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_non_default_ctor2_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_default_ctor2_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_non_default_ctor2_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_default_ctor2.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_non_default_ctor2_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_default_ctor2_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_non_default_ctor2_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_default_ctor2_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_non_default_ctor2_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_default_ctor2_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_non_default_ctor2_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_default_ctor2.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_non_default_ctor2_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_default_ctor2_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_non_default_ctor2_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_default_ctor2_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_non_default_ctor2_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_non_default_ctor2_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_null_ptr_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_null_ptr.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_null_ptr_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_null_ptr_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_null_ptr_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_null_ptr_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_null_ptr_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_null_ptr_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_null_ptr_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_null_ptr.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_null_ptr_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_null_ptr_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_null_ptr_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_null_ptr_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_null_ptr_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_null_ptr_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_null_ptr_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_null_ptr.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_null_ptr_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_null_ptr_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_null_ptr_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_null_ptr_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_null_ptr_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_null_ptr_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_null_ptr_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_null_ptr.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_null_ptr_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_null_ptr_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_null_ptr_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_null_ptr_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_null_ptr_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_null_ptr_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_null_ptr_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_null_ptr.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_null_ptr_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_null_ptr_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_null_ptr_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_null_ptr_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_null_ptr_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_null_ptr_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_nvp_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_nvp.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_nvp_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_nvp_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_nvp_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_nvp_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_nvp_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_nvp_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_nvp_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_nvp.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_nvp_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_nvp_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_nvp_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_nvp_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_nvp_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_nvp_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_nvp_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_nvp.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_nvp_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_nvp_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_nvp_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_nvp_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_nvp_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_nvp_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_nvp_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_nvp.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_nvp_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_nvp_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_nvp_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_nvp_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_nvp_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_nvp_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_object_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_object.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_object_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_object_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_object_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_object_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_object_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_object_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_object_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_object.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_object_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_object_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_object_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_object_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_object_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_object_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_nvp_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_nvp.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_object_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_object.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_nvp_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_nvp_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_nvp_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_nvp_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_nvp_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_nvp_xml_warchive.test +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_object_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_object_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_object_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_object_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_object_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_object_binary_archive.test +...on 700th target... +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_object_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_object.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_object_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_object_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_object_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_object_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_object_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_object_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_object_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_object.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_object_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_object_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_object_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_object_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_object_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_object_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_primitive_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_primitive.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_primitive_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_primitive_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_primitive_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_primitive_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_primitive_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_primitive_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_primitive_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_primitive.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_primitive_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_primitive_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_primitive_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_primitive_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_primitive_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_primitive_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_primitive_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_primitive.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_primitive_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_primitive_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_primitive_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_primitive_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_primitive_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_primitive_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_primitive_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_primitive.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_primitive_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_primitive_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_primitive_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_primitive_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_primitive_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_primitive_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_primitive_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_primitive.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_primitive_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_primitive_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_primitive_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_primitive_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_primitive_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_primitive_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_priority_queue_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_priority_queue.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_priority_queue_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_priority_queue_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_priority_queue_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_priority_queue_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_priority_queue_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_priority_queue_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_priority_queue_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_priority_queue.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_priority_queue_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_priority_queue_text_warchive +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_priority_queue_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_priority_queue.o +testing.capture-output ../../../bin.v2/libs/serialization/test/test_priority_queue_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_priority_queue_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_priority_queue_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_priority_queue_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_priority_queue_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_priority_queue.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_priority_queue_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_priority_queue_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_priority_queue_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_priority_queue_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_priority_queue_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_priority_queue_binary_archive.test +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_priority_queue_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_priority_queue_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_priority_queue_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_priority_queue_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_priority_queue_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_priority_queue_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_priority_queue_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_priority_queue.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_priority_queue_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_priority_queue_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_priority_queue_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_priority_queue_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_priority_queue_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_priority_queue_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_queue_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_queue.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_queue_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_queue.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_queue_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_queue_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_queue_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_queue_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_queue_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_queue_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_queue_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_queue.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_queue_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_queue_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_queue_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_queue_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_queue_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_queue_text_warchive.test +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_queue_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_queue_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_queue_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_queue_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_queue_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_queue_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_queue_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_queue.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_queue_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_queue_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_queue_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_queue_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_queue_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_queue_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_queue_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_queue.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_queue_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_queue_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_queue_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_queue_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_queue_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_queue_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_recursion_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_recursion.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_recursion_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_recursion_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_recursion_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_recursion_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_recursion_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_recursion_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_recursion_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_recursion.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_recursion_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_recursion_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_recursion_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_recursion_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_recursion_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_recursion_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_recursion_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_recursion.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_recursion_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_recursion_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_recursion_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_recursion_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_recursion_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_recursion_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_recursion_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_recursion.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_recursion_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_recursion_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_recursion_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_recursion_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_recursion_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_recursion_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_recursion_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_recursion.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_recursion_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_recursion_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_recursion_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_recursion_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_recursion_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_recursion_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_registered_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_registered.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_registered_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_registered_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_registered_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_registered_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_registered_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_registered_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_registered_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_registered.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_registered_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_registered_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_registered_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_registered_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_registered_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_registered_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_registered_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_registered.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_registered_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_registered.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_registered_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_registered_binary_archive +...on 800th target... +testing.capture-output ../../../bin.v2/libs/serialization/test/test_registered_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_registered_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_registered_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_registered_binary_archive.test +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_registered_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_registered_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_registered_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_registered_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_registered_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_registered_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_registered_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_registered.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_registered_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_registered_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_registered_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_registered_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_registered_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_registered_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_set_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_set.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_set_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_set_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_set_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_set_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_set_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_set_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_set_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_set.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_set_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_set_xml_archive +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_set_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_set.o +testing.capture-output ../../../bin.v2/libs/serialization/test/test_set_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_set_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_set_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_set_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_set_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_set.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_set_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_set_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_set_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_set_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_set_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_set_text_warchive.test +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_set_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_set_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_set_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_set_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_set_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_set_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_set_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_set.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_set_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_set_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_set_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_set_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_set_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_set_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_set_boost_unordered_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_set_boost_unordered.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_set_boost_unordered_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_set_boost_unordered.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_set_boost_unordered_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_set_boost_unordered_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_set_boost_unordered_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_set_boost_unordered_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_set_boost_unordered_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_set_boost_unordered_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_set_boost_unordered_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_set_boost_unordered.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_set_boost_unordered_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_set_boost_unordered_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_set_boost_unordered_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_set_boost_unordered_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_set_boost_unordered_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_set_boost_unordered_text_warchive.test +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_set_boost_unordered_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_set_boost_unordered_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_set_boost_unordered_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_set_boost_unordered_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_set_boost_unordered_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_set_boost_unordered_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_set_boost_unordered_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_set_boost_unordered.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_set_boost_unordered_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_set_boost_unordered_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_set_boost_unordered_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_set_boost_unordered_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_set_boost_unordered_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_set_boost_unordered_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_set_boost_unordered_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_set_boost_unordered.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_set_boost_unordered_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_set_boost_unordered_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_set_boost_unordered_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_set_boost_unordered_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_set_boost_unordered_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_set_boost_unordered_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_simple_class_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_simple_class.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_simple_class_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_simple_class_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_simple_class_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_simple_class_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_simple_class_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_simple_class_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_simple_class_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_simple_class.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_simple_class_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_simple_class_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_simple_class_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_simple_class_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_simple_class_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_simple_class_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_simple_class_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_simple_class.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_simple_class_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_simple_class_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_simple_class_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_simple_class_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_simple_class_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_simple_class_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_simple_class_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_simple_class.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_simple_class_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_simple_class_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_simple_class_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_simple_class_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_simple_class_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_simple_class_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_simple_class_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_simple_class.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_simple_class_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_simple_class_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_simple_class_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_simple_class_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_simple_class_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_simple_class_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_simple_class_ptr_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_simple_class_ptr.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_simple_class_ptr_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_simple_class_ptr_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_simple_class_ptr_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_simple_class_ptr_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_simple_class_ptr_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_simple_class_ptr_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_simple_class_ptr_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_simple_class_ptr.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_simple_class_ptr_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_simple_class_ptr_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_simple_class_ptr_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_simple_class_ptr_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_simple_class_ptr_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_simple_class_ptr_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_simple_class_ptr_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_simple_class_ptr.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_simple_class_ptr_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_simple_class_ptr_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_simple_class_ptr_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_simple_class_ptr_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_simple_class_ptr_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_simple_class_ptr_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_simple_class_ptr_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_simple_class_ptr.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_simple_class_ptr_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_simple_class_ptr.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_simple_class_ptr_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_simple_class_ptr_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_simple_class_ptr_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_simple_class_ptr_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_simple_class_ptr_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_simple_class_ptr_binary_archive.test +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_simple_class_ptr_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_simple_class_ptr_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_simple_class_ptr_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_simple_class_ptr_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_simple_class_ptr_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_simple_class_ptr_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_split_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_split.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_split_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_split_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_split_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_split_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_split_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_split_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_split_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_split.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_split_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_split_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_split_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_split_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_split_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_split_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_split_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_split.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_split_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_split.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_split_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_split_binary_archive +...on 900th target... +testing.capture-output ../../../bin.v2/libs/serialization/test/test_split_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_split_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_split_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_split_binary_archive.test +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_split_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_split_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_split_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_split_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_split_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_split_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_split_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_split.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_split_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_split_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_split_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_split_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_split_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_split_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_stack_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_stack.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_stack_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_stack.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_stack_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_stack_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_stack_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_stack_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_stack_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_stack_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_stack_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_stack.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_stack_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_stack_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_stack_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_stack_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_stack_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_stack_text_warchive.test +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_stack_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_stack_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_stack_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_stack_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_stack_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_stack_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_stack_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_stack.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_stack_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_stack_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_stack_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_stack_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_stack_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_stack_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_stack_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_stack.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_stack_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_stack_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_stack_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_stack_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_stack_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_stack_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_tracking_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_tracking.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_tracking_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_tracking_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_tracking_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_tracking_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_tracking_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_tracking_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_tracking_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_tracking.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_tracking_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_tracking_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_tracking_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_tracking_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_tracking_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_tracking_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_tracking_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_tracking.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_tracking_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_tracking_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_tracking_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_tracking_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_tracking_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_tracking_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_tracking_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_tracking.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_tracking_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_tracking_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_tracking_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_tracking_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_tracking_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_tracking_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_tracking_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_tracking.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_tracking_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_tracking_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_tracking_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_tracking_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_tracking_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_tracking_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_unregistered_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_unregistered.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_unregistered_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_unregistered_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_unregistered_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_unregistered_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_unregistered_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_unregistered_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_unregistered_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_unregistered.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_unregistered_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_unregistered_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_unregistered_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_unregistered_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_unregistered_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_unregistered_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_unregistered_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_unregistered.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_unregistered_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_unregistered_xml_archive +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_unregistered_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_unregistered.o +testing.capture-output ../../../bin.v2/libs/serialization/test/test_unregistered_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_unregistered_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_unregistered_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_unregistered_xml_archive.test +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_unregistered_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_unregistered_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_unregistered_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_unregistered_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_unregistered_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_unregistered_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_unique_ptr_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_unique_ptr.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_unique_ptr_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_unique_ptr_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_unique_ptr_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_unique_ptr_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_unique_ptr_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_unique_ptr_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_unregistered_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_unregistered.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_unregistered_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_unregistered_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_unregistered_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_unregistered_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_unregistered_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_unregistered_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_unique_ptr_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_unique_ptr.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_unique_ptr_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_unique_ptr_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_unique_ptr_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_unique_ptr_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_unique_ptr_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_unique_ptr_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_unique_ptr_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_unique_ptr.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_unique_ptr_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_unique_ptr_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_unique_ptr_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_unique_ptr_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_unique_ptr_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_unique_ptr_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_unique_ptr_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_unique_ptr.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_unique_ptr_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_unique_ptr_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_unique_ptr_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_unique_ptr_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_unique_ptr_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_unique_ptr_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_unique_ptr_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_unique_ptr.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_unique_ptr_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_unique_ptr_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_unique_ptr_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_unique_ptr_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_unique_ptr_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_unique_ptr_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_valarray_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_valarray.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_valarray_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_valarray_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_valarray_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_valarray_text_archive.run +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_valarray_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_valarray.o +**passed** ../../../bin.v2/libs/serialization/test/test_valarray_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_valarray_text_archive.test +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_valarray_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_valarray_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_valarray_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_valarray_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_valarray_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_valarray_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_valarray_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_valarray.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_valarray_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_valarray.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_valarray_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_valarray_binary_archive +...on 1000th target... +testing.capture-output ../../../bin.v2/libs/serialization/test/test_valarray_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_valarray_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_valarray_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_valarray_binary_archive.test +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_valarray_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_valarray_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_valarray_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_valarray_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_valarray_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_valarray_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_valarray_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_valarray.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_valarray_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_valarray_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_valarray_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_valarray_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_valarray_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_valarray_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_variant_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_variant.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_variant_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_variant_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_variant_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_variant_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_variant_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_variant_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_variant_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_variant.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_variant_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_variant_text_warchive +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_variant_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_variant.o +testing.capture-output ../../../bin.v2/libs/serialization/test/test_variant_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_variant_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_variant_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_variant_text_warchive.test +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_variant_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_variant_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_variant_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_variant_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_variant_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_variant_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_variant_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_variant.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_variant_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_variant_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_variant_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_variant_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_variant_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_variant_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_vector_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_vector.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_vector_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_vector_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_vector_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_vector_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_vector_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_vector_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_vector_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_vector.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_vector_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_vector_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_vector_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_vector_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_vector_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_vector_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_vector_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_vector.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_vector_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_vector_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_vector_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_vector_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_vector_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_vector_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_variant_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_variant.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_variant_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_variant_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_variant_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_variant_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_variant_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_variant_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_vector_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_vector.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_vector_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_vector_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_vector_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_vector_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_vector_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_vector_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_vector_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_vector.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_vector_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_vector_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_vector_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_vector_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_vector_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_vector_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_new_operator_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_new_operator.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_new_operator_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_new_operator_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_new_operator_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_new_operator_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_new_operator_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_new_operator_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_new_operator_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_new_operator.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_new_operator_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_new_operator_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_new_operator_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_new_operator_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_new_operator_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_new_operator_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_new_operator_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_new_operator.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_new_operator_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_new_operator_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_new_operator_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_new_operator_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_new_operator_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_new_operator_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_new_operator_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_new_operator.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_new_operator_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_new_operator_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_new_operator_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_new_operator_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_new_operator_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_new_operator_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_new_operator_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_new_operator.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_new_operator_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_new_operator_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_new_operator_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_new_operator_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_new_operator_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_new_operator_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_optional_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_optional.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_optional_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_optional_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_optional_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_optional_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_optional_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_optional_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_optional_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_optional.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_optional_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_optional_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_optional_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_optional_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_optional_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_optional_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_optional_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_optional.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_optional_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_optional_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_optional_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_optional_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_optional_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_optional_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_optional_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_optional.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_optional_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_optional_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_optional_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_optional_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_optional_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_optional_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_optional_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_optional.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_optional_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_optional_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_optional_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_optional_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_optional_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_optional_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_shared_ptr_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_shared_ptr_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_shared_ptr_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_shared_ptr_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_shared_ptr_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_shared_ptr_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_shared_ptr_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_shared_ptr_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_shared_ptr_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_shared_ptr_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_shared_ptr_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_shared_ptr_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_binary_archive.test +...on 1100th target... +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_shared_ptr_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_shared_ptr_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_shared_ptr_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_shared_ptr_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_shared_ptr_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_shared_ptr_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_shared_ptr_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_shared_ptr_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_shared_ptr_multi_base_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_multi_base.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_shared_ptr_multi_base_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_multi_base_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_shared_ptr_multi_base_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_multi_base_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_shared_ptr_multi_base_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_multi_base_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_shared_ptr_multi_base_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_multi_base.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_shared_ptr_multi_base_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_multi_base_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_shared_ptr_multi_base_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_multi_base_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_shared_ptr_multi_base_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_multi_base_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_shared_ptr_multi_base_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_multi_base.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_shared_ptr_multi_base_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_multi_base_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_shared_ptr_multi_base_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_multi_base_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_shared_ptr_multi_base_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_multi_base_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_shared_ptr_multi_base_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_multi_base.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_shared_ptr_multi_base_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_multi_base_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_shared_ptr_multi_base_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_multi_base_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_shared_ptr_multi_base_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_multi_base_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_shared_ptr_132_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_132.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_shared_ptr_multi_base_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_multi_base.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_shared_ptr_132_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_132_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_shared_ptr_132_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_132_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_shared_ptr_132_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_132_text_archive.test +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_shared_ptr_multi_base_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_multi_base_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_shared_ptr_multi_base_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_multi_base_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_shared_ptr_multi_base_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_multi_base_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_shared_ptr_132_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_132.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_shared_ptr_132_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_132_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_shared_ptr_132_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_132_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_shared_ptr_132_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_132_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_shared_ptr_132_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_132.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_shared_ptr_132_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_132_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_shared_ptr_132_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_132_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_shared_ptr_132_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_132_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_polymorphic_polymorphic_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_shared_ptr_132_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_132.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_shared_ptr_132_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_132_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_shared_ptr_132_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_132_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_shared_ptr_132_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_132_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_shared_ptr_132_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_132.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_shared_ptr_132_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_132_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_shared_ptr_132_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_132_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_shared_ptr_132_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_shared_ptr_132_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_polymorphic_polymorphic_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic_A.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_polymorphic_polymorphic_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic_polymorphic_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_polymorphic_polymorphic_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic_polymorphic_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_polymorphic_polymorphic_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic_polymorphic_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_polymorphic_polymorphic_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic_A.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_polymorphic_polymorphic_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_polymorphic_polymorphic_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic_polymorphic_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_polymorphic_polymorphic_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic_polymorphic_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_polymorphic_polymorphic_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic_polymorphic_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_polymorphic_polymorphic_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_polymorphic_polymorphic_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic_A.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_polymorphic_polymorphic_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic_polymorphic_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_polymorphic_polymorphic_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic_polymorphic_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_polymorphic_polymorphic_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic_polymorphic_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_polymorphic_polymorphic_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic_A.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_polymorphic_polymorphic_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_polymorphic_polymorphic_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic_polymorphic_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_polymorphic_polymorphic_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic_polymorphic_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_polymorphic_polymorphic_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic_polymorphic_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_polymorphic_polymorphic_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic_A.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_polymorphic_polymorphic_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_polymorphic_polymorphic_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic_polymorphic_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_polymorphic_polymorphic_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic_polymorphic_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_polymorphic_polymorphic_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic_polymorphic_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_polymorphic2_polymorphic_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic2imp.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_polymorphic2_polymorphic_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic2.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_polymorphic2_polymorphic_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic2imp.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_polymorphic2_polymorphic_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic2_polymorphic_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_polymorphic2_polymorphic_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic2_polymorphic_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_polymorphic2_polymorphic_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic2_polymorphic_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_polymorphic2_polymorphic_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic2.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_polymorphic2_polymorphic_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic2_polymorphic_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_polymorphic2_polymorphic_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic2_polymorphic_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_polymorphic2_polymorphic_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic2_polymorphic_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_polymorphic2_polymorphic_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic2imp.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_polymorphic2_polymorphic_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic2.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_polymorphic2_polymorphic_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic2_polymorphic_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_polymorphic2_polymorphic_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic2_polymorphic_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_polymorphic2_polymorphic_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic2_polymorphic_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_polymorphic2_polymorphic_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic2imp.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_polymorphic2_polymorphic_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic2.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_polymorphic2_polymorphic_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic2_polymorphic_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_polymorphic2_polymorphic_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic2_polymorphic_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_polymorphic2_polymorphic_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic2_polymorphic_xml_archive.test +...on 1200th target... +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_polymorphic2_polymorphic_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic2imp.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_polymorphic2_polymorphic_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic2.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_polymorphic2_polymorphic_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic2_polymorphic_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_polymorphic2_polymorphic_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic2_polymorphic_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_polymorphic2_polymorphic_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_polymorphic2_polymorphic_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_p_helper_polymorphic_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_p_helper.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_p_helper_polymorphic_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_p_helper_polymorphic_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_p_helper_polymorphic_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_p_helper_polymorphic_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_p_helper_polymorphic_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_p_helper_polymorphic_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_p_helper_polymorphic_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_p_helper.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_p_helper_polymorphic_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_p_helper_polymorphic_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_p_helper_polymorphic_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_p_helper_polymorphic_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_p_helper_polymorphic_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_p_helper_polymorphic_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_p_helper_polymorphic_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_p_helper.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_p_helper_polymorphic_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_p_helper_polymorphic_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_p_helper_polymorphic_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_p_helper_polymorphic_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_p_helper_polymorphic_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_p_helper_polymorphic_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_p_helper_polymorphic_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_p_helper.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_p_helper_polymorphic_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_p_helper_polymorphic_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_p_helper_polymorphic_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_p_helper_polymorphic_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_p_helper_polymorphic_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_p_helper_polymorphic_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_dll_exported_polymorphic_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_derived1.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_dll_exported_polymorphic_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_dll_exported.o +In file included from test_dll_exported.cpp:51: +./polymorphic_base.hpp:29:13: warning: polymorphic_base imported [-W#pragma-messages] + #pragma message ("polymorphic_base imported") + ^ +In file included from test_dll_exported.cpp:56: +./polymorphic_derived2.hpp:29:13: warning: polymorphic_derived2 imported [-W#pragma-messages] + #pragma message ("polymorphic_derived2 imported") + ^ +2 warnings generated. +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/clang-darwin-03/debug/threading-multi/visibility-hidden/dll_polymorphic_derived2.o +In file included from dll_polymorphic_derived2.cpp:13: +In file included from ./polymorphic_derived2.cpp:15: +./polymorphic_base.hpp:29:13: warning: polymorphic_base imported [-W#pragma-messages] + #pragma message ("polymorphic_base imported") + ^ +In file included from dll_polymorphic_derived2.cpp:13: +In file included from ./polymorphic_derived2.cpp:16: +./polymorphic_derived2.hpp:32:13: warning: polymorphic_derived2 exported [-W#pragma-messages] + #pragma message ("polymorphic_derived2 exported") + ^ +2 warnings generated. +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/clang-darwin-03/debug/threading-multi/visibility-hidden/dll_polymorphic_base.o +In file included from dll_polymorphic_base.cpp:12: +In file included from ./polymorphic_base.cpp:13: +./polymorphic_base.hpp:32:13: warning: polymorphic_base exported [-W#pragma-messages] + #pragma message ("polymorphic_base exported") + ^ +1 warning generated. +clang-darwin.link.dll ../../../bin.v2/libs/serialization/test/clang-darwin-03/debug/threading-multi/visibility-hidden/libdll_polymorphic_base.dylib +clang-darwin.link.dll ../../../bin.v2/libs/serialization/test/clang-darwin-03/debug/threading-multi/visibility-hidden/libdll_polymorphic_derived2.dylib +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_dll_exported_polymorphic_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_dll_exported_polymorphic_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_dll_exported_polymorphic_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_dll_exported_polymorphic_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_dll_exported_polymorphic_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_dll_exported_polymorphic_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_p_helper_polymorphic_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_p_helper.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_p_helper_polymorphic_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_p_helper_polymorphic_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_p_helper_polymorphic_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_p_helper_polymorphic_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_p_helper_polymorphic_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_p_helper_polymorphic_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_dll_exported_polymorphic_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_derived1.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_dll_exported_polymorphic_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_dll_exported.o +In file included from test_dll_exported.cpp:51: +./polymorphic_base.hpp:29:13: warning: polymorphic_base imported [-W#pragma-messages] + #pragma message ("polymorphic_base imported") + ^ +In file included from test_dll_exported.cpp:56: +./polymorphic_derived2.hpp:29:13: warning: polymorphic_derived2 imported [-W#pragma-messages] + #pragma message ("polymorphic_derived2 imported") + ^ +2 warnings generated. +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_dll_exported_polymorphic_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_dll_exported_polymorphic_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_dll_exported_polymorphic_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_dll_exported_polymorphic_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_dll_exported_polymorphic_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_dll_exported_polymorphic_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_dll_exported_polymorphic_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_derived1.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_dll_exported_polymorphic_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_dll_exported.o +In file included from test_dll_exported.cpp:51: +./polymorphic_base.hpp:29:13: warning: polymorphic_base imported [-W#pragma-messages] + #pragma message ("polymorphic_base imported") + ^ +In file included from test_dll_exported.cpp:56: +./polymorphic_derived2.hpp:29:13: warning: polymorphic_derived2 imported [-W#pragma-messages] + #pragma message ("polymorphic_derived2 imported") + ^ +2 warnings generated. +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_dll_exported_polymorphic_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_dll_exported_polymorphic_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_dll_exported_polymorphic_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_dll_exported_polymorphic_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_dll_exported_polymorphic_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_dll_exported_polymorphic_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_dll_exported_polymorphic_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_dll_exported.o +In file included from test_dll_exported.cpp:51: +./polymorphic_base.hpp:29:13: warning: polymorphic_base imported [-W#pragma-messages] + #pragma message ("polymorphic_base imported") + ^ +In file included from test_dll_exported.cpp:56: +./polymorphic_derived2.hpp:29:13: warning: polymorphic_derived2 imported [-W#pragma-messages] + #pragma message ("polymorphic_derived2 imported") + ^ +2 warnings generated. +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_dll_exported_polymorphic_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_derived1.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_dll_exported_polymorphic_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_dll_exported_polymorphic_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_dll_exported_polymorphic_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_dll_exported_polymorphic_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_dll_exported_polymorphic_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_dll_exported_polymorphic_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_dll_exported_polymorphic_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_derived1.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_dll_exported_polymorphic_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_dll_exported.o +In file included from test_dll_exported.cpp:51: +./polymorphic_base.hpp:29:13: warning: polymorphic_base imported [-W#pragma-messages] + #pragma message ("polymorphic_base imported") + ^ +In file included from test_dll_exported.cpp:56: +./polymorphic_derived2.hpp:29:13: warning: polymorphic_derived2 imported [-W#pragma-messages] + #pragma message ("polymorphic_derived2 imported") + ^ +2 warnings generated. +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_dll_exported_polymorphic_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_dll_exported_polymorphic_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_dll_exported_polymorphic_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_dll_exported_polymorphic_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_dll_exported_polymorphic_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_dll_exported_polymorphic_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_no_rtti_polymorphic_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_base.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_no_rtti_polymorphic_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_derived1.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_no_rtti_polymorphic_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_derived2.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_no_rtti_polymorphic_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_no_rtti.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_no_rtti_polymorphic_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_no_rtti_polymorphic_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_no_rtti_polymorphic_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_no_rtti_polymorphic_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_no_rtti_polymorphic_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_no_rtti_polymorphic_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_no_rtti_polymorphic_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_base.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_no_rtti_polymorphic_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_derived1.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_no_rtti_polymorphic_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_no_rtti.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_no_rtti_polymorphic_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_derived2.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_no_rtti_polymorphic_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_no_rtti_polymorphic_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_no_rtti_polymorphic_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_no_rtti_polymorphic_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_no_rtti_polymorphic_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_no_rtti_polymorphic_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_no_rtti_polymorphic_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_base.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_no_rtti_polymorphic_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_derived1.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_no_rtti_polymorphic_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_derived2.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_no_rtti_polymorphic_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_no_rtti.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_no_rtti_polymorphic_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_no_rtti_polymorphic_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_no_rtti_polymorphic_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_no_rtti_polymorphic_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_no_rtti_polymorphic_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_no_rtti_polymorphic_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_no_rtti_polymorphic_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_base.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_no_rtti_polymorphic_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_derived1.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_no_rtti_polymorphic_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_derived2.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_no_rtti_polymorphic_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_no_rtti.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_no_rtti_polymorphic_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_no_rtti_polymorphic_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_no_rtti_polymorphic_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_no_rtti_polymorphic_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_no_rtti_polymorphic_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_no_rtti_polymorphic_xml_archive.test +...on 1300th target... +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_no_rtti_polymorphic_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_base.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_no_rtti_polymorphic_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_derived1.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_no_rtti_polymorphic_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_no_rtti.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_no_rtti_polymorphic_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_derived2.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_no_rtti_polymorphic_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_no_rtti_polymorphic_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_no_rtti_polymorphic_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_no_rtti_polymorphic_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_no_rtti_polymorphic_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_no_rtti_polymorphic_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_exported_polymorphic_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_base.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_exported_polymorphic_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_derived1.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_exported_polymorphic_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_exported.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_exported_polymorphic_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_derived2.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_exported_polymorphic_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_exported_polymorphic_text_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_exported_polymorphic_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_exported_polymorphic_text_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_exported_polymorphic_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_exported_polymorphic_text_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_exported_polymorphic_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_base.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_exported_polymorphic_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_derived1.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_exported_polymorphic_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_derived2.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_exported_polymorphic_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_exported.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_exported_polymorphic_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_exported_polymorphic_text_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_exported_polymorphic_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_exported_polymorphic_text_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_exported_polymorphic_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_exported_polymorphic_text_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_exported_polymorphic_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_base.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_exported_polymorphic_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_derived1.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_exported_polymorphic_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_derived2.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_exported_polymorphic_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_exported.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_exported_polymorphic_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_exported_polymorphic_binary_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_exported_polymorphic_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_exported_polymorphic_binary_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_exported_polymorphic_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_exported_polymorphic_binary_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_exported_polymorphic_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_base.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_exported_polymorphic_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_exported.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_exported_polymorphic_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_derived1.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_exported_polymorphic_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_derived2.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_exported_polymorphic_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_exported_polymorphic_xml_archive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_exported_polymorphic_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_exported_polymorphic_xml_archive.run +**passed** ../../../bin.v2/libs/serialization/test/test_exported_polymorphic_xml_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_exported_polymorphic_xml_archive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_exported_polymorphic_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_base.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_exported_polymorphic_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_derived1.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_inclusion.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_inclusion.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_exported_polymorphic_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_exported.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_inclusion.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_inclusion +testing.capture-output ../../../bin.v2/libs/serialization/test/test_inclusion.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_inclusion.run +**passed** ../../../bin.v2/libs/serialization/test/test_inclusion.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_inclusion.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_exported_polymorphic_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/polymorphic_derived2.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_exported_polymorphic_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_exported_polymorphic_xml_warchive +testing.capture-output ../../../bin.v2/libs/serialization/test/test_exported_polymorphic_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_exported_polymorphic_xml_warchive.run +**passed** ../../../bin.v2/libs/serialization/test/test_exported_polymorphic_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_exported_polymorphic_xml_warchive.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_inclusion2.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_inclusion2.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_inclusion2.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_inclusion2 +testing.capture-output ../../../bin.v2/libs/serialization/test/test_inclusion2.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_inclusion2.run +**passed** ../../../bin.v2/libs/serialization/test/test_inclusion2.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_inclusion2.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_private_ctor.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_private_ctor.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_private_ctor.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_private_ctor +testing.capture-output ../../../bin.v2/libs/serialization/test/test_private_ctor.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_private_ctor.run +**passed** ../../../bin.v2/libs/serialization/test/test_private_ctor.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_private_ctor.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/clang-darwin-03/debug/threading-multi/visibility-hidden/dll_a.o +In file included from dll_a.cpp:14: +./A.hpp:40:13: warning: A exported [-W#pragma-messages] + #pragma message ("A exported") + ^ +1 warning generated. +clang-darwin.link.dll ../../../bin.v2/libs/serialization/test/clang-darwin-03/debug/threading-multi/visibility-hidden/libdll_a.dylib +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_dll_simple.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_dll_simple.o +In file included from test_dll_simple.cpp:33: +./A.hpp:37:13: warning: A imported [-W#pragma-messages] + #pragma message("A imported") + ^ +1 warning generated. +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_dll_simple.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_dll_simple +testing.capture-output ../../../bin.v2/libs/serialization/test/test_dll_simple.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_dll_simple.run +**passed** ../../../bin.v2/libs/serialization/test/test_dll_simple.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_dll_simple.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_void_cast.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_void_cast.o +test_void_cast.cpp:18:10: warning: private field 'a' is not used [-Wunused-private-field] + char a; + ^ +test_void_cast.cpp:23:9: warning: private field 'b' is not used [-Wunused-private-field] + int b; + ^ +test_void_cast.cpp:28:10: warning: private field 'c' is not used [-Wunused-private-field] + long c; + ^ +test_void_cast.cpp:33:10: warning: private field 'd' is not used [-Wunused-private-field] + char d[32]; + ^ +4 warnings generated. +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_void_cast.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_void_cast +testing.capture-output ../../../bin.v2/libs/serialization/test/test_void_cast.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_void_cast.run +**passed** ../../../bin.v2/libs/serialization/test/test_void_cast.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_void_cast.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_mult_archive_types.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_mult_archive_types.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_mult_archive_types.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_mult_archive_types +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_reset_object_address.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_reset_object_address.o +testing.capture-output ../../../bin.v2/libs/serialization/test/test_mult_archive_types.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_mult_archive_types.run +**passed** ../../../bin.v2/libs/serialization/test/test_mult_archive_types.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_mult_archive_types.test +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_reset_object_address.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_reset_object_address +testing.capture-output ../../../bin.v2/libs/serialization/test/test_reset_object_address.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_reset_object_address.run +**passed** ../../../bin.v2/libs/serialization/test/test_reset_object_address.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_reset_object_address.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_iterators.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_iterators.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_iterators.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_iterators +testing.capture-output ../../../bin.v2/libs/serialization/test/test_iterators.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_iterators.run +**passed** ../../../bin.v2/libs/serialization/test/test_iterators.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_iterators.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_iterators_base64.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_iterators_base64.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_iterators_base64.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_iterators_base64 +testing.capture-output ../../../bin.v2/libs/serialization/test/test_iterators_base64.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_iterators_base64.run +**passed** ../../../bin.v2/libs/serialization/test/test_iterators_base64.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_iterators_base64.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_smart_cast.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_smart_cast.o +test_smart_cast.cpp:20:10: warning: private field 'a' is not used [-Wunused-private-field] + char a; + ^ +test_smart_cast.cpp:25:9: warning: private field 'b' is not used [-Wunused-private-field] + int b; + ^ +test_smart_cast.cpp:35:10: warning: private field 'c' is not used [-Wunused-private-field] + long c; + ^ +test_smart_cast.cpp:122:10: warning: private field 'a' is not used [-Wunused-private-field] + char a; + ^ +test_smart_cast.cpp:129:9: warning: private field 'b' is not used [-Wunused-private-field] + int b; + ^ +test_smart_cast.cpp:141:10: warning: private field 'c' is not used [-Wunused-private-field] + long c; + ^ +6 warnings generated. +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_smart_cast.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_smart_cast +testing.capture-output ../../../bin.v2/libs/serialization/test/test_smart_cast.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_smart_cast.run +**passed** ../../../bin.v2/libs/serialization/test/test_smart_cast.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_smart_cast.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_codecvt_null.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_codecvt_null.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_codecvt_null.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_codecvt_null +testing.capture-output ../../../bin.v2/libs/serialization/test/test_codecvt_null.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_codecvt_null.run +**passed** ../../../bin.v2/libs/serialization/test/test_codecvt_null.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_codecvt_null.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_singleton.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_singleton.o +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_singleton.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_singleton +testing.capture-output ../../../bin.v2/libs/serialization/test/test_singleton.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_singleton.run +**passed** ../../../bin.v2/libs/serialization/test/test_singleton.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_singleton.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_singleton_inherited.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_singleton_inherited.o +test_singleton_inherited.cpp:26:32: warning: unknown warning group '-Wterminate', ignored [-Wunknown-warning-option] +#pragma GCC diagnostic ignored "-Wterminate" + ^ +1 warning generated. +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_singleton_inherited.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_singleton_inherited +testing.capture-output ../../../bin.v2/libs/serialization/test/test_singleton_inherited.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_singleton_inherited.run +**passed** ../../../bin.v2/libs/serialization/test/test_singleton_inherited.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_singleton_inherited.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_singleton_plain.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_singleton_plain.o +test_singleton_plain.cpp:25:32: warning: unknown warning group '-Wterminate', ignored [-Wunknown-warning-option] +#pragma GCC diagnostic ignored "-Wterminate" + ^ +1 warning generated. +clang-darwin.link ../../../bin.v2/libs/serialization/test/test_singleton_plain.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_singleton_plain +testing.capture-output ../../../bin.v2/libs/serialization/test/test_singleton_plain.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_singleton_plain.run +**passed** ../../../bin.v2/libs/serialization/test/test_singleton_plain.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_singleton_plain.test +...on 1400th target... +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_not_serializable.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_not_serializable.o +In file included from test_not_serializable.cpp:14: +In file included from ./test_tools.hpp:246: +In file included from ./text_archive.hpp:8: +In file included from ../../../boost/archive/text_oarchive.hpp:31: +In file included from ../../../boost/archive/basic_text_oarchive.hpp:29: +In file included from ../../../boost/archive/detail/common_oarchive.hpp:22: +In file included from ../../../boost/archive/detail/interface_oarchive.hpp:23: +In file included from ../../../boost/archive/detail/oserializer.hpp:40: +In file included from ../../../boost/serialization/extended_type_info_typeid.hpp:37: +../../../boost/serialization/access.hpp:116:11: error: no member named 'serialize' in 'A' + t.serialize(ar, file_version); + ~ ^ +../../../boost/serialization/serialization.hpp:68:13: note: in instantiation of function template specialization 'boost::serialization::access::serialize<boost::archive::text_oarchive, A>' requested here + access::serialize(ar, t, static_cast<unsigned int>(file_version)); + ^ +../../../boost/serialization/serialization.hpp:126:5: note: in instantiation of function template specialization 'boost::serialization::serialize<boost::archive::text_oarchive, A>' requested here + serialize(ar, t, v); + ^ +../../../boost/archive/detail/oserializer.hpp:153:27: note: in instantiation of function template specialization 'boost::serialization::serialize_adl<boost::archive::text_oarchive, A>' requested here + boost::serialization::serialize_adl( + ^ +../../../boost/serialization/singleton.hpp:147:5: note: in instantiation of member function 'boost::archive::detail::oserializer<boost::archive::text_oarchive, A>::save_object_data' requested here + singleton_wrapper(){ + ^ +../../../boost/serialization/singleton.hpp:171:47: note: in instantiation of member function 'boost::serialization::detail::singleton_wrapper<boost::archive::detail::oserializer<boost::archive::text_oarchive, A> >::singleton_wrapper' requested here + static detail::singleton_wrapper< T > t; + ^ +../../../boost/serialization/singleton.hpp:196:16: note: (skipping 15 contexts in backtrace; use -ftemplate-backtrace-limit=0 to see all) + return get_instance(); + ^ +../../../boost/archive/detail/oserializer.hpp:539:12: note: in instantiation of function template specialization 'boost::archive::detail::save_non_pointer_type<boost::archive::text_oarchive>::invoke<boost::serialization::nvp<A> >' requested here + typex::invoke(ar, t); + ^ +../../../boost/archive/detail/common_oarchive.hpp:71:18: note: in instantiation of function template specialization 'boost::archive::save<boost::archive::text_oarchive, const boost::serialization::nvp<A> >' requested here + archive::save(* this->This(), t); + ^ +../../../boost/archive/basic_text_oarchive.hpp:83:39: note: in instantiation of function template specialization 'boost::archive::detail::common_oarchive<boost::archive::text_oarchive>::save_override<const boost::serialization::nvp<A> >' requested here + this->detail_common_oarchive::save_override(t); + ^ +../../../boost/archive/detail/interface_oarchive.hpp:70:23: note: in instantiation of function template specialization 'boost::archive::basic_text_oarchive<boost::archive::text_oarchive>::save_override<const boost::serialization::nvp<A> >' requested here + this->This()->save_override(t); + ^ +test_not_serializable.cpp:28:8: note: in instantiation of function template specialization 'boost::archive::detail::interface_oarchive<boost::archive::text_oarchive>::operator<<<boost::serialization::nvp<A> >' requested here + oa << BOOST_SERIALIZATION_NVP(a); + ^ +In file included from test_not_serializable.cpp:14: +In file included from ./test_tools.hpp:246: +In file included from ./text_archive.hpp:8: +In file included from ../../../boost/archive/text_oarchive.hpp:31: +In file included from ../../../boost/archive/basic_text_oarchive.hpp:29: +In file included from ../../../boost/archive/detail/common_oarchive.hpp:22: +In file included from ../../../boost/archive/detail/interface_oarchive.hpp:23: +In file included from ../../../boost/archive/detail/oserializer.hpp:70: +../../../boost/archive/detail/check.hpp:60:5: error: implicit instantiation of undefined template 'boost::STATIC_ASSERTION_FAILURE<false>' + BOOST_STATIC_ASSERT(typex::value); + ^ +../../../boost/static_assert.hpp:154:13: note: expanded from macro 'BOOST_STATIC_ASSERT' + sizeof(::boost::STATIC_ASSERTION_FAILURE< BOOST_STATIC_ASSERT_BOOL_CAST( __VA_ARGS__ ) >)>\ + ^ +../../../boost/archive/detail/iserializer.hpp:460:9: note: in instantiation of function template specialization 'boost::archive::detail::check_object_level<A>' requested here + check_object_level< T >(); + ^ +../../../boost/archive/detail/iserializer.hpp:624:12: note: in instantiation of function template specialization 'boost::archive::detail::load_non_pointer_type<boost::archive::text_iarchive>::invoke<A>' requested here + typex::invoke(ar, t); + ^ +../../../boost/archive/detail/common_iarchive.hpp:67:18: note: in instantiation of function template specialization 'boost::archive::load<boost::archive::text_iarchive, A>' requested here + archive::load(* this->This(), t); + ^ +../../../boost/archive/basic_text_iarchive.hpp:70:39: note: in instantiation of function template specialization 'boost::archive::detail::common_iarchive<boost::archive::text_iarchive>::load_override<A>' requested here + this->detail_common_iarchive::load_override(t); + ^ +../../../boost/archive/text_iarchive.hpp:82:39: note: in instantiation of function template specialization 'boost::archive::basic_text_iarchive<boost::archive::text_iarchive>::load_override<A>' requested here + basic_text_iarchive<Archive>::load_override(t); + ^ +../../../boost/archive/detail/interface_iarchive.hpp:68:23: note: (skipping 9 contexts in backtrace; use -ftemplate-backtrace-limit=0 to see all) + this->This()->load_override(t); + ^ +../../../boost/archive/detail/common_iarchive.hpp:67:18: note: in instantiation of function template specialization 'boost::archive::load<boost::archive::text_iarchive, const boost::serialization::nvp<A> >' requested here + archive::load(* this->This(), t); + ^ +../../../boost/archive/basic_text_iarchive.hpp:70:39: note: in instantiation of function template specialization 'boost::archive::detail::common_iarchive<boost::archive::text_iarchive>::load_override<const boost::serialization::nvp<A> >' requested here + this->detail_common_iarchive::load_override(t); + ^ +../../../boost/archive/text_iarchive.hpp:82:39: note: in instantiation of function template specialization 'boost::archive::basic_text_iarchive<boost::archive::text_iarchive>::load_override<const boost::serialization::nvp<A> >' requested here + basic_text_iarchive<Archive>::load_override(t); + ^ +../../../boost/archive/detail/interface_iarchive.hpp:68:23: note: in instantiation of function template specialization 'boost::archive::text_iarchive_impl<boost::archive::text_iarchive>::load_override<const boost::serialization::nvp<A> >' requested here + this->This()->load_override(t); + ^ +test_not_serializable.cpp:35:8: note: in instantiation of function template specialization 'boost::archive::detail::interface_iarchive<boost::archive::text_iarchive>::operator>><const boost::serialization::nvp<A> >' requested here + ia >> BOOST_SERIALIZATION_NVP(a); + ^ +../../../boost/static_assert.hpp:79:26: note: template is declared here +template <bool x> struct STATIC_ASSERTION_FAILURE; + ^ +In file included from test_not_serializable.cpp:14: +In file included from ./test_tools.hpp:246: +In file included from ./text_archive.hpp:8: +In file included from ../../../boost/archive/text_oarchive.hpp:31: +In file included from ../../../boost/archive/basic_text_oarchive.hpp:29: +In file included from ../../../boost/archive/detail/common_oarchive.hpp:22: +In file included from ../../../boost/archive/detail/interface_oarchive.hpp:23: +In file included from ../../../boost/archive/detail/oserializer.hpp:40: +In file included from ../../../boost/serialization/extended_type_info_typeid.hpp:37: +../../../boost/serialization/access.hpp:116:11: error: no member named 'serialize' in 'A' + t.serialize(ar, file_version); + ~ ^ +../../../boost/serialization/serialization.hpp:68:13: note: in instantiation of function template specialization 'boost::serialization::access::serialize<boost::archive::text_iarchive, A>' requested here + access::serialize(ar, t, static_cast<unsigned int>(file_version)); + ^ +../../../boost/serialization/serialization.hpp:126:5: note: in instantiation of function template specialization 'boost::serialization::serialize<boost::archive::text_iarchive, A>' requested here + serialize(ar, t, v); + ^ +../../../boost/archive/detail/iserializer.hpp:187:27: note: in instantiation of function template specialization 'boost::serialization::serialize_adl<boost::archive::text_iarchive, A>' requested here + boost::serialization::serialize_adl( + ^ +../../../boost/serialization/singleton.hpp:147:5: note: in instantiation of member function 'boost::archive::detail::iserializer<boost::archive::text_iarchive, A>::load_object_data' requested here + singleton_wrapper(){ + ^ +../../../boost/serialization/singleton.hpp:171:47: note: in instantiation of member function 'boost::serialization::detail::singleton_wrapper<boost::archive::detail::iserializer<boost::archive::text_iarchive, A> >::singleton_wrapper' requested here + static detail::singleton_wrapper< T > t; + ^ +../../../boost/serialization/singleton.hpp:196:16: note: (skipping 17 contexts in backtrace; use -ftemplate-backtrace-limit=0 to see all) + return get_instance(); + ^ +../../../boost/archive/detail/common_iarchive.hpp:67:18: note: in instantiation of function template specialization 'boost::archive::load<boost::archive::text_iarchive, const boost::serialization::nvp<A> >' requested here + archive::load(* this->This(), t); + ^ +../../../boost/archive/basic_text_iarchive.hpp:70:39: note: in instantiation of function template specialization 'boost::archive::detail::common_iarchive<boost::archive::text_iarchive>::load_override<const boost::serialization::nvp<A> >' requested here + this->detail_common_iarchive::load_override(t); + ^ +../../../boost/archive/text_iarchive.hpp:82:39: note: in instantiation of function template specialization 'boost::archive::basic_text_iarchive<boost::archive::text_iarchive>::load_override<const boost::serialization::nvp<A> >' requested here + basic_text_iarchive<Archive>::load_override(t); + ^ +../../../boost/archive/detail/interface_iarchive.hpp:68:23: note: in instantiation of function template specialization 'boost::archive::text_iarchive_impl<boost::archive::text_iarchive>::load_override<const boost::serialization::nvp<A> >' requested here + this->This()->load_override(t); + ^ +test_not_serializable.cpp:35:8: note: in instantiation of function template specialization 'boost::archive::detail::interface_iarchive<boost::archive::text_iarchive>::operator>><const boost::serialization::nvp<A> >' requested here + ia >> BOOST_SERIALIZATION_NVP(a); + ^ +3 errors generated. +(failed-as-expected) ../../../bin.v2/libs/serialization/test/test_not_serializable.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_not_serializable.o +**passed** ../../../bin.v2/libs/serialization/test/test_not_serializable.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_not_serializable.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_traits_fail.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_traits_fail.o +test_traits_fail.cpp:24:1: error: implicit instantiation of undefined template 'boost::STATIC_ASSERTION_FAILURE<false>' +BOOST_CLASS_TRACKING(A, boost::serialization::track_never) +^ +../../../boost/serialization/tracking.hpp:108:5: note: expanded from macro 'BOOST_CLASS_TRACKING' + BOOST_STATIC_ASSERT(( \ + ^ +../../../boost/static_assert.hpp:154:13: note: expanded from macro 'BOOST_STATIC_ASSERT' + sizeof(::boost::STATIC_ASSERTION_FAILURE< BOOST_STATIC_ASSERT_BOOL_CAST( __VA_ARGS__ ) >)>\ + ^ +../../../boost/static_assert.hpp:79:26: note: template is declared here +template <bool x> struct STATIC_ASSERTION_FAILURE; + ^ +1 error generated. +(failed-as-expected) ../../../bin.v2/libs/serialization/test/test_traits_fail.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_traits_fail.o +**passed** ../../../bin.v2/libs/serialization/test/test_traits_fail.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_traits_fail.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_const_load_fail1.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_const_load_fail1.o +In file included from test_const_load_fail1.cpp:11: +In file included from ../../../boost/archive/text_iarchive.hpp:24: +In file included from ../../../boost/archive/basic_text_iarchive.hpp:30: +In file included from ../../../boost/archive/detail/common_iarchive.hpp:23: +In file included from ../../../boost/archive/detail/interface_iarchive.hpp:22: +In file included from ../../../boost/archive/detail/iserializer.hpp:90: +../../../boost/archive/detail/check.hpp:162:5: error: implicit instantiation of undefined template 'boost::STATIC_ASSERTION_FAILURE<false>' + BOOST_STATIC_ASSERT(typex::value); + ^ +../../../boost/static_assert.hpp:154:13: note: expanded from macro 'BOOST_STATIC_ASSERT' + sizeof(::boost::STATIC_ASSERTION_FAILURE< BOOST_STATIC_ASSERT_BOOL_CAST( __VA_ARGS__ ) >)>\ + ^ +../../../boost/archive/detail/iserializer.hpp:609:13: note: in instantiation of function template specialization 'boost::archive::detail::check_const_loading<const A>' requested here + detail::check_const_loading< T >(); + ^ +../../../boost/archive/detail/common_iarchive.hpp:67:18: note: in instantiation of function template specialization 'boost::archive::load<boost::archive::text_iarchive, const A>' requested here + archive::load(* this->This(), t); + ^ +../../../boost/archive/basic_text_iarchive.hpp:70:39: note: in instantiation of function template specialization 'boost::archive::detail::common_iarchive<boost::archive::text_iarchive>::load_override<const A>' requested here + this->detail_common_iarchive::load_override(t); + ^ +../../../boost/archive/text_iarchive.hpp:82:39: note: in instantiation of function template specialization 'boost::archive::basic_text_iarchive<boost::archive::text_iarchive>::load_override<const A>' requested here + basic_text_iarchive<Archive>::load_override(t); + ^ +../../../boost/archive/detail/interface_iarchive.hpp:68:23: note: in instantiation of function template specialization 'boost::archive::text_iarchive_impl<boost::archive::text_iarchive>::load_override<const A>' requested here + this->This()->load_override(t); + ^ +test_const_load_fail1.cpp:22:8: note: in instantiation of function template specialization 'boost::archive::detail::interface_iarchive<boost::archive::text_iarchive>::operator>><const A>' requested here + ia >> a; + ^ +../../../boost/static_assert.hpp:79:26: note: template is declared here +template <bool x> struct STATIC_ASSERTION_FAILURE; + ^ +1 error generated. +(failed-as-expected) ../../../bin.v2/libs/serialization/test/test_const_load_fail1.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_const_load_fail1.o +**passed** ../../../bin.v2/libs/serialization/test/test_const_load_fail1.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_const_load_fail1.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_const_load_fail2.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_const_load_fail2.o +In file included from test_const_load_fail2.cpp:11: +In file included from ../../../boost/archive/text_iarchive.hpp:24: +In file included from ../../../boost/archive/basic_text_iarchive.hpp:30: +In file included from ../../../boost/archive/detail/common_iarchive.hpp:23: +In file included from ../../../boost/archive/detail/interface_iarchive.hpp:22: +In file included from ../../../boost/archive/detail/iserializer.hpp:90: +../../../boost/archive/detail/check.hpp:162:5: error: implicit instantiation of undefined template 'boost::STATIC_ASSERTION_FAILURE<false>' + BOOST_STATIC_ASSERT(typex::value); + ^ +../../../boost/static_assert.hpp:154:13: note: expanded from macro 'BOOST_STATIC_ASSERT' + sizeof(::boost::STATIC_ASSERTION_FAILURE< BOOST_STATIC_ASSERT_BOOL_CAST( __VA_ARGS__ ) >)>\ + ^ +../../../boost/archive/detail/iserializer.hpp:609:13: note: in instantiation of function template specialization 'boost::archive::detail::check_const_loading<A *const>' requested here + detail::check_const_loading< T >(); + ^ +../../../boost/archive/detail/common_iarchive.hpp:67:18: note: in instantiation of function template specialization 'boost::archive::load<boost::archive::text_iarchive, A *const>' requested here + archive::load(* this->This(), t); + ^ +../../../boost/archive/basic_text_iarchive.hpp:70:39: note: in instantiation of function template specialization 'boost::archive::detail::common_iarchive<boost::archive::text_iarchive>::load_override<A *const>' requested here + this->detail_common_iarchive::load_override(t); + ^ +../../../boost/archive/text_iarchive.hpp:82:39: note: in instantiation of function template specialization 'boost::archive::basic_text_iarchive<boost::archive::text_iarchive>::load_override<A *const>' requested here + basic_text_iarchive<Archive>::load_override(t); + ^ +../../../boost/archive/detail/interface_iarchive.hpp:68:23: note: in instantiation of function template specialization 'boost::archive::text_iarchive_impl<boost::archive::text_iarchive>::load_override<A *const>' requested here + this->This()->load_override(t); + ^ +test_const_load_fail2.cpp:22:8: note: in instantiation of function template specialization 'boost::archive::detail::interface_iarchive<boost::archive::text_iarchive>::operator>><A *const>' requested here + ia >> a; + ^ +../../../boost/static_assert.hpp:79:26: note: template is declared here +template <bool x> struct STATIC_ASSERTION_FAILURE; + ^ +In file included from test_const_load_fail2.cpp:11: +In file included from ../../../boost/archive/text_iarchive.hpp:24: +In file included from ../../../boost/archive/basic_text_iarchive.hpp:30: +In file included from ../../../boost/archive/detail/common_iarchive.hpp:23: +In file included from ../../../boost/archive/detail/interface_iarchive.hpp:22: +../../../boost/archive/detail/iserializer.hpp:552:15: error: cannot assign to variable 't' with const-qualified type 'A *const &' + t = pointer_tweak(newbpis_ptr->get_eti(), t, *t); + ~ ^ +../../../boost/archive/detail/iserializer.hpp:624:12: note: in instantiation of function template specialization 'boost::archive::detail::load_pointer_type<boost::archive::text_iarchive>::invoke<A *const>' requested here + typex::invoke(ar, t); + ^ +../../../boost/archive/detail/common_iarchive.hpp:67:18: note: in instantiation of function template specialization 'boost::archive::load<boost::archive::text_iarchive, A *const>' requested here + archive::load(* this->This(), t); + ^ +../../../boost/archive/basic_text_iarchive.hpp:70:39: note: in instantiation of function template specialization 'boost::archive::detail::common_iarchive<boost::archive::text_iarchive>::load_override<A *const>' requested here + this->detail_common_iarchive::load_override(t); + ^ +../../../boost/archive/text_iarchive.hpp:82:39: note: in instantiation of function template specialization 'boost::archive::basic_text_iarchive<boost::archive::text_iarchive>::load_override<A *const>' requested here + basic_text_iarchive<Archive>::load_override(t); + ^ +../../../boost/archive/detail/interface_iarchive.hpp:68:23: note: in instantiation of function template specialization 'boost::archive::text_iarchive_impl<boost::archive::text_iarchive>::load_override<A *const>' requested here + this->This()->load_override(t); + ^ +test_const_load_fail2.cpp:22:8: note: in instantiation of function template specialization 'boost::archive::detail::interface_iarchive<boost::archive::text_iarchive>::operator>><A *const>' requested here + ia >> a; + ^ +../../../boost/archive/detail/iserializer.hpp:538:45: note: variable 't' declared const here + static void invoke(Archive & ar, Tptr & t){ + ~~~~~~~^ +2 errors generated. +(failed-as-expected) ../../../bin.v2/libs/serialization/test/test_const_load_fail2.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_const_load_fail2.o +**passed** ../../../bin.v2/libs/serialization/test/test_const_load_fail2.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_const_load_fail2.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_const_load_fail3.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_const_load_fail3.o +In file included from test_const_load_fail3.cpp:11: +In file included from ../../../boost/archive/text_iarchive.hpp:24: +In file included from ../../../boost/archive/basic_text_iarchive.hpp:30: +In file included from ../../../boost/archive/detail/common_iarchive.hpp:23: +In file included from ../../../boost/archive/detail/interface_iarchive.hpp:22: +In file included from ../../../boost/archive/detail/iserializer.hpp:90: +../../../boost/archive/detail/check.hpp:162:5: error: implicit instantiation of undefined template 'boost::STATIC_ASSERTION_FAILURE<false>' + BOOST_STATIC_ASSERT(typex::value); + ^ +../../../boost/static_assert.hpp:154:13: note: expanded from macro 'BOOST_STATIC_ASSERT' + sizeof(::boost::STATIC_ASSERTION_FAILURE< BOOST_STATIC_ASSERT_BOOL_CAST( __VA_ARGS__ ) >)>\ + ^ +../../../boost/archive/detail/iserializer.hpp:609:13: note: in instantiation of function template specialization 'boost::archive::detail::check_const_loading<const A *const>' requested here + detail::check_const_loading< T >(); + ^ +../../../boost/archive/detail/common_iarchive.hpp:67:18: note: in instantiation of function template specialization 'boost::archive::load<boost::archive::text_iarchive, const A *const>' requested here + archive::load(* this->This(), t); + ^ +../../../boost/archive/basic_text_iarchive.hpp:70:39: note: in instantiation of function template specialization 'boost::archive::detail::common_iarchive<boost::archive::text_iarchive>::load_override<const A *const>' requested here + this->detail_common_iarchive::load_override(t); + ^ +../../../boost/archive/text_iarchive.hpp:82:39: note: in instantiation of function template specialization 'boost::archive::basic_text_iarchive<boost::archive::text_iarchive>::load_override<const A *const>' requested here + basic_text_iarchive<Archive>::load_override(t); + ^ +../../../boost/archive/detail/interface_iarchive.hpp:68:23: note: in instantiation of function template specialization 'boost::archive::text_iarchive_impl<boost::archive::text_iarchive>::load_override<const A *const>' requested here + this->This()->load_override(t); + ^ +test_const_load_fail3.cpp:21:8: note: in instantiation of function template specialization 'boost::archive::detail::interface_iarchive<boost::archive::text_iarchive>::operator>><const A *const>' requested here + ia >> a; + ^ +../../../boost/static_assert.hpp:79:26: note: template is declared here +template <bool x> struct STATIC_ASSERTION_FAILURE; + ^ +In file included from test_const_load_fail3.cpp:11: +In file included from ../../../boost/archive/text_iarchive.hpp:24: +In file included from ../../../boost/archive/basic_text_iarchive.hpp:30: +In file included from ../../../boost/archive/detail/common_iarchive.hpp:23: +In file included from ../../../boost/archive/detail/interface_iarchive.hpp:22: +../../../boost/archive/detail/iserializer.hpp:552:15: error: cannot assign to variable 't' with const-qualified type 'const A *const &' + t = pointer_tweak(newbpis_ptr->get_eti(), t, *t); + ~ ^ +../../../boost/archive/detail/iserializer.hpp:624:12: note: in instantiation of function template specialization 'boost::archive::detail::load_pointer_type<boost::archive::text_iarchive>::invoke<const A *const>' requested here + typex::invoke(ar, t); + ^ +../../../boost/archive/detail/common_iarchive.hpp:67:18: note: in instantiation of function template specialization 'boost::archive::load<boost::archive::text_iarchive, const A *const>' requested here + archive::load(* this->This(), t); + ^ +../../../boost/archive/basic_text_iarchive.hpp:70:39: note: in instantiation of function template specialization 'boost::archive::detail::common_iarchive<boost::archive::text_iarchive>::load_override<const A *const>' requested here + this->detail_common_iarchive::load_override(t); + ^ +../../../boost/archive/text_iarchive.hpp:82:39: note: in instantiation of function template specialization 'boost::archive::basic_text_iarchive<boost::archive::text_iarchive>::load_override<const A *const>' requested here + basic_text_iarchive<Archive>::load_override(t); + ^ +../../../boost/archive/detail/interface_iarchive.hpp:68:23: note: in instantiation of function template specialization 'boost::archive::text_iarchive_impl<boost::archive::text_iarchive>::load_override<const A *const>' requested here + this->This()->load_override(t); + ^ +test_const_load_fail3.cpp:21:8: note: in instantiation of function template specialization 'boost::archive::detail::interface_iarchive<boost::archive::text_iarchive>::operator>><const A *const>' requested here + ia >> a; + ^ +../../../boost/archive/detail/iserializer.hpp:538:45: note: variable 't' declared const here + static void invoke(Archive & ar, Tptr & t){ + ~~~~~~~^ +2 errors generated. +(failed-as-expected) ../../../bin.v2/libs/serialization/test/test_const_load_fail3.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_const_load_fail3.o +**passed** ../../../bin.v2/libs/serialization/test/test_const_load_fail3.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_const_load_fail3.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_const_load_fail1_nvp.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_const_load_fail1_nvp.o +In file included from test_const_load_fail1_nvp.cpp:11: +In file included from ../../../boost/archive/text_iarchive.hpp:24: +In file included from ../../../boost/archive/basic_text_iarchive.hpp:30: +In file included from ../../../boost/archive/detail/common_iarchive.hpp:23: +In file included from ../../../boost/archive/detail/interface_iarchive.hpp:22: +In file included from ../../../boost/archive/detail/iserializer.hpp:90: +../../../boost/archive/detail/check.hpp:162:5: error: implicit instantiation of undefined template 'boost::STATIC_ASSERTION_FAILURE<false>' + BOOST_STATIC_ASSERT(typex::value); + ^ +../../../boost/static_assert.hpp:154:13: note: expanded from macro 'BOOST_STATIC_ASSERT' + sizeof(::boost::STATIC_ASSERTION_FAILURE< BOOST_STATIC_ASSERT_BOOL_CAST( __VA_ARGS__ ) >)>\ + ^ +../../../boost/archive/detail/iserializer.hpp:609:13: note: in instantiation of function template specialization 'boost::archive::detail::check_const_loading<const A>' requested here + detail::check_const_loading< T >(); + ^ +../../../boost/archive/detail/common_iarchive.hpp:67:18: note: in instantiation of function template specialization 'boost::archive::load<boost::archive::text_iarchive, const A>' requested here + archive::load(* this->This(), t); + ^ +../../../boost/archive/basic_text_iarchive.hpp:70:39: note: in instantiation of function template specialization 'boost::archive::detail::common_iarchive<boost::archive::text_iarchive>::load_override<const A>' requested here + this->detail_common_iarchive::load_override(t); + ^ +../../../boost/archive/text_iarchive.hpp:82:39: note: in instantiation of function template specialization 'boost::archive::basic_text_iarchive<boost::archive::text_iarchive>::load_override<const A>' requested here + basic_text_iarchive<Archive>::load_override(t); + ^ +../../../boost/archive/detail/interface_iarchive.hpp:68:23: note: in instantiation of function template specialization 'boost::archive::text_iarchive_impl<boost::archive::text_iarchive>::load_override<const A>' requested here + this->This()->load_override(t); + ^ +../../../boost/serialization/nvp.hpp:56:8: note: (skipping 8 contexts in backtrace; use -ftemplate-backtrace-limit=0 to see all) + ar >> t.value(); + ^ +../../../boost/archive/detail/common_iarchive.hpp:67:18: note: in instantiation of function template specialization 'boost::archive::load<boost::archive::text_iarchive, const boost::serialization::nvp<const A> >' requested here + archive::load(* this->This(), t); + ^ +../../../boost/archive/basic_text_iarchive.hpp:70:39: note: in instantiation of function template specialization 'boost::archive::detail::common_iarchive<boost::archive::text_iarchive>::load_override<const boost::serialization::nvp<const A> >' requested here + this->detail_common_iarchive::load_override(t); + ^ +../../../boost/archive/text_iarchive.hpp:82:39: note: in instantiation of function template specialization 'boost::archive::basic_text_iarchive<boost::archive::text_iarchive>::load_override<const boost::serialization::nvp<const A> >' requested here + basic_text_iarchive<Archive>::load_override(t); + ^ +../../../boost/archive/detail/interface_iarchive.hpp:68:23: note: in instantiation of function template specialization 'boost::archive::text_iarchive_impl<boost::archive::text_iarchive>::load_override<const boost::serialization::nvp<const A> >' requested here + this->This()->load_override(t); + ^ +test_const_load_fail1_nvp.cpp:23:8: note: in instantiation of function template specialization 'boost::archive::detail::interface_iarchive<boost::archive::text_iarchive>::operator>><const boost::serialization::nvp<const A> >' requested here + ia >> BOOST_SERIALIZATION_NVP(a); + ^ +../../../boost/static_assert.hpp:79:26: note: template is declared here +template <bool x> struct STATIC_ASSERTION_FAILURE; + ^ +1 error generated. +(failed-as-expected) ../../../bin.v2/libs/serialization/test/test_const_load_fail1_nvp.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_const_load_fail1_nvp.o +**passed** ../../../bin.v2/libs/serialization/test/test_const_load_fail1_nvp.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_const_load_fail1_nvp.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_const_load_fail2_nvp.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_const_load_fail2_nvp.o +In file included from test_const_load_fail2_nvp.cpp:11: +In file included from ../../../boost/archive/text_iarchive.hpp:24: +In file included from ../../../boost/archive/basic_text_iarchive.hpp:30: +In file included from ../../../boost/archive/detail/common_iarchive.hpp:23: +In file included from ../../../boost/archive/detail/interface_iarchive.hpp:22: +In file included from ../../../boost/archive/detail/iserializer.hpp:90: +../../../boost/archive/detail/check.hpp:162:5: error: implicit instantiation of undefined template 'boost::STATIC_ASSERTION_FAILURE<false>' + BOOST_STATIC_ASSERT(typex::value); + ^ +../../../boost/static_assert.hpp:154:13: note: expanded from macro 'BOOST_STATIC_ASSERT' + sizeof(::boost::STATIC_ASSERTION_FAILURE< BOOST_STATIC_ASSERT_BOOL_CAST( __VA_ARGS__ ) >)>\ + ^ +../../../boost/archive/detail/iserializer.hpp:609:13: note: in instantiation of function template specialization 'boost::archive::detail::check_const_loading<A *const>' requested here + detail::check_const_loading< T >(); + ^ +../../../boost/archive/detail/common_iarchive.hpp:67:18: note: in instantiation of function template specialization 'boost::archive::load<boost::archive::text_iarchive, A *const>' requested here + archive::load(* this->This(), t); + ^ +../../../boost/archive/basic_text_iarchive.hpp:70:39: note: in instantiation of function template specialization 'boost::archive::detail::common_iarchive<boost::archive::text_iarchive>::load_override<A *const>' requested here + this->detail_common_iarchive::load_override(t); + ^ +../../../boost/archive/text_iarchive.hpp:82:39: note: in instantiation of function template specialization 'boost::archive::basic_text_iarchive<boost::archive::text_iarchive>::load_override<A *const>' requested here + basic_text_iarchive<Archive>::load_override(t); + ^ +../../../boost/archive/detail/interface_iarchive.hpp:68:23: note: in instantiation of function template specialization 'boost::archive::text_iarchive_impl<boost::archive::text_iarchive>::load_override<A *const>' requested here + this->This()->load_override(t); + ^ +../../../boost/serialization/nvp.hpp:56:8: note: (skipping 8 contexts in backtrace; use -ftemplate-backtrace-limit=0 to see all) + ar >> t.value(); + ^ +../../../boost/archive/detail/common_iarchive.hpp:67:18: note: in instantiation of function template specialization 'boost::archive::load<boost::archive::text_iarchive, const boost::serialization::nvp<A *const> >' requested here + archive::load(* this->This(), t); + ^ +../../../boost/archive/basic_text_iarchive.hpp:70:39: note: in instantiation of function template specialization 'boost::archive::detail::common_iarchive<boost::archive::text_iarchive>::load_override<const boost::serialization::nvp<A *const> >' requested here + this->detail_common_iarchive::load_override(t); + ^ +../../../boost/archive/text_iarchive.hpp:82:39: note: in instantiation of function template specialization 'boost::archive::basic_text_iarchive<boost::archive::text_iarchive>::load_override<const boost::serialization::nvp<A *const> >' requested here + basic_text_iarchive<Archive>::load_override(t); + ^ +../../../boost/archive/detail/interface_iarchive.hpp:68:23: note: in instantiation of function template specialization 'boost::archive::text_iarchive_impl<boost::archive::text_iarchive>::load_override<const boost::serialization::nvp<A *const> >' requested here + this->This()->load_override(t); + ^ +test_const_load_fail2_nvp.cpp:23:8: note: in instantiation of function template specialization 'boost::archive::detail::interface_iarchive<boost::archive::text_iarchive>::operator>><const boost::serialization::nvp<A *const> >' requested here + ia >> BOOST_SERIALIZATION_NVP(a); + ^ +../../../boost/static_assert.hpp:79:26: note: template is declared here +template <bool x> struct STATIC_ASSERTION_FAILURE; + ^ +In file included from test_const_load_fail2_nvp.cpp:11: +In file included from ../../../boost/archive/text_iarchive.hpp:24: +In file included from ../../../boost/archive/basic_text_iarchive.hpp:30: +In file included from ../../../boost/archive/detail/common_iarchive.hpp:23: +In file included from ../../../boost/archive/detail/interface_iarchive.hpp:22: +../../../boost/archive/detail/iserializer.hpp:552:15: error: cannot assign to variable 't' with const-qualified type 'A *const &' + t = pointer_tweak(newbpis_ptr->get_eti(), t, *t); + ~ ^ +../../../boost/archive/detail/iserializer.hpp:624:12: note: in instantiation of function template specialization 'boost::archive::detail::load_pointer_type<boost::archive::text_iarchive>::invoke<A *const>' requested here + typex::invoke(ar, t); + ^ +../../../boost/archive/detail/common_iarchive.hpp:67:18: note: in instantiation of function template specialization 'boost::archive::load<boost::archive::text_iarchive, A *const>' requested here + archive::load(* this->This(), t); + ^ +../../../boost/archive/basic_text_iarchive.hpp:70:39: note: in instantiation of function template specialization 'boost::archive::detail::common_iarchive<boost::archive::text_iarchive>::load_override<A *const>' requested here + this->detail_common_iarchive::load_override(t); + ^ +../../../boost/archive/text_iarchive.hpp:82:39: note: in instantiation of function template specialization 'boost::archive::basic_text_iarchive<boost::archive::text_iarchive>::load_override<A *const>' requested here + basic_text_iarchive<Archive>::load_override(t); + ^ +../../../boost/archive/detail/interface_iarchive.hpp:68:23: note: in instantiation of function template specialization 'boost::archive::text_iarchive_impl<boost::archive::text_iarchive>::load_override<A *const>' requested here + this->This()->load_override(t); + ^ +../../../boost/serialization/nvp.hpp:56:8: note: (skipping 8 contexts in backtrace; use -ftemplate-backtrace-limit=0 to see all) + ar >> t.value(); + ^ +../../../boost/archive/detail/common_iarchive.hpp:67:18: note: in instantiation of function template specialization 'boost::archive::load<boost::archive::text_iarchive, const boost::serialization::nvp<A *const> >' requested here + archive::load(* this->This(), t); + ^ +../../../boost/archive/basic_text_iarchive.hpp:70:39: note: in instantiation of function template specialization 'boost::archive::detail::common_iarchive<boost::archive::text_iarchive>::load_override<const boost::serialization::nvp<A *const> >' requested here + this->detail_common_iarchive::load_override(t); + ^ +../../../boost/archive/text_iarchive.hpp:82:39: note: in instantiation of function template specialization 'boost::archive::basic_text_iarchive<boost::archive::text_iarchive>::load_override<const boost::serialization::nvp<A *const> >' requested here + basic_text_iarchive<Archive>::load_override(t); + ^ +../../../boost/archive/detail/interface_iarchive.hpp:68:23: note: in instantiation of function template specialization 'boost::archive::text_iarchive_impl<boost::archive::text_iarchive>::load_override<const boost::serialization::nvp<A *const> >' requested here + this->This()->load_override(t); + ^ +test_const_load_fail2_nvp.cpp:23:8: note: in instantiation of function template specialization 'boost::archive::detail::interface_iarchive<boost::archive::text_iarchive>::operator>><const boost::serialization::nvp<A *const> >' requested here + ia >> BOOST_SERIALIZATION_NVP(a); + ^ +../../../boost/archive/detail/iserializer.hpp:538:45: note: variable 't' declared const here + static void invoke(Archive & ar, Tptr & t){ + ~~~~~~~^ +2 errors generated. +(failed-as-expected) ../../../bin.v2/libs/serialization/test/test_const_load_fail2_nvp.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_const_load_fail2_nvp.o +**passed** ../../../bin.v2/libs/serialization/test/test_const_load_fail2_nvp.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_const_load_fail2_nvp.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_const_load_fail3_nvp.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_const_load_fail3_nvp.o +In file included from test_const_load_fail3_nvp.cpp:11: +In file included from ../../../boost/archive/text_iarchive.hpp:24: +In file included from ../../../boost/archive/basic_text_iarchive.hpp:30: +In file included from ../../../boost/archive/detail/common_iarchive.hpp:23: +In file included from ../../../boost/archive/detail/interface_iarchive.hpp:22: +In file included from ../../../boost/archive/detail/iserializer.hpp:90: +../../../boost/archive/detail/check.hpp:162:5: error: implicit instantiation of undefined template 'boost::STATIC_ASSERTION_FAILURE<false>' + BOOST_STATIC_ASSERT(typex::value); + ^ +../../../boost/static_assert.hpp:154:13: note: expanded from macro 'BOOST_STATIC_ASSERT' + sizeof(::boost::STATIC_ASSERTION_FAILURE< BOOST_STATIC_ASSERT_BOOL_CAST( __VA_ARGS__ ) >)>\ + ^ +../../../boost/archive/detail/iserializer.hpp:609:13: note: in instantiation of function template specialization 'boost::archive::detail::check_const_loading<const A *const>' requested here + detail::check_const_loading< T >(); + ^ +../../../boost/archive/detail/common_iarchive.hpp:67:18: note: in instantiation of function template specialization 'boost::archive::load<boost::archive::text_iarchive, const A *const>' requested here + archive::load(* this->This(), t); + ^ +../../../boost/archive/basic_text_iarchive.hpp:70:39: note: in instantiation of function template specialization 'boost::archive::detail::common_iarchive<boost::archive::text_iarchive>::load_override<const A *const>' requested here + this->detail_common_iarchive::load_override(t); + ^ +../../../boost/archive/text_iarchive.hpp:82:39: note: in instantiation of function template specialization 'boost::archive::basic_text_iarchive<boost::archive::text_iarchive>::load_override<const A *const>' requested here + basic_text_iarchive<Archive>::load_override(t); + ^ +../../../boost/archive/detail/interface_iarchive.hpp:68:23: note: in instantiation of function template specialization 'boost::archive::text_iarchive_impl<boost::archive::text_iarchive>::load_override<const A *const>' requested here + this->This()->load_override(t); + ^ +../../../boost/serialization/nvp.hpp:56:8: note: (skipping 8 contexts in backtrace; use -ftemplate-backtrace-limit=0 to see all) + ar >> t.value(); + ^ +../../../boost/archive/detail/common_iarchive.hpp:67:18: note: in instantiation of function template specialization 'boost::archive::load<boost::archive::text_iarchive, const boost::serialization::nvp<const A *const> >' requested here + archive::load(* this->This(), t); + ^ +../../../boost/archive/basic_text_iarchive.hpp:70:39: note: in instantiation of function template specialization 'boost::archive::detail::common_iarchive<boost::archive::text_iarchive>::load_override<const boost::serialization::nvp<const A *const> >' requested here + this->detail_common_iarchive::load_override(t); + ^ +../../../boost/archive/text_iarchive.hpp:82:39: note: in instantiation of function template specialization 'boost::archive::basic_text_iarchive<boost::archive::text_iarchive>::load_override<const boost::serialization::nvp<const A *const> >' requested here + basic_text_iarchive<Archive>::load_override(t); + ^ +../../../boost/archive/detail/interface_iarchive.hpp:68:23: note: in instantiation of function template specialization 'boost::archive::text_iarchive_impl<boost::archive::text_iarchive>::load_override<const boost::serialization::nvp<const A *const> >' requested here + this->This()->load_override(t); + ^ +test_const_load_fail3_nvp.cpp:23:8: note: in instantiation of function template specialization 'boost::archive::detail::interface_iarchive<boost::archive::text_iarchive>::operator>><const boost::serialization::nvp<const A *const> >' requested here + ia >> BOOST_SERIALIZATION_NVP(a); + ^ +../../../boost/static_assert.hpp:79:26: note: template is declared here +template <bool x> struct STATIC_ASSERTION_FAILURE; + ^ +In file included from test_const_load_fail3_nvp.cpp:11: +In file included from ../../../boost/archive/text_iarchive.hpp:24: +In file included from ../../../boost/archive/basic_text_iarchive.hpp:30: +In file included from ../../../boost/archive/detail/common_iarchive.hpp:23: +In file included from ../../../boost/archive/detail/interface_iarchive.hpp:22: +../../../boost/archive/detail/iserializer.hpp:552:15: error: cannot assign to variable 't' with const-qualified type 'const A *const &' + t = pointer_tweak(newbpis_ptr->get_eti(), t, *t); + ~ ^ +../../../boost/archive/detail/iserializer.hpp:624:12: note: in instantiation of function template specialization 'boost::archive::detail::load_pointer_type<boost::archive::text_iarchive>::invoke<const A *const>' requested here + typex::invoke(ar, t); + ^ +../../../boost/archive/detail/common_iarchive.hpp:67:18: note: in instantiation of function template specialization 'boost::archive::load<boost::archive::text_iarchive, const A *const>' requested here + archive::load(* this->This(), t); + ^ +../../../boost/archive/basic_text_iarchive.hpp:70:39: note: in instantiation of function template specialization 'boost::archive::detail::common_iarchive<boost::archive::text_iarchive>::load_override<const A *const>' requested here + this->detail_common_iarchive::load_override(t); + ^ +../../../boost/archive/text_iarchive.hpp:82:39: note: in instantiation of function template specialization 'boost::archive::basic_text_iarchive<boost::archive::text_iarchive>::load_override<const A *const>' requested here + basic_text_iarchive<Archive>::load_override(t); + ^ +../../../boost/archive/detail/interface_iarchive.hpp:68:23: note: in instantiation of function template specialization 'boost::archive::text_iarchive_impl<boost::archive::text_iarchive>::load_override<const A *const>' requested here + this->This()->load_override(t); + ^ +../../../boost/serialization/nvp.hpp:56:8: note: (skipping 8 contexts in backtrace; use -ftemplate-backtrace-limit=0 to see all) + ar >> t.value(); + ^ +../../../boost/archive/detail/common_iarchive.hpp:67:18: note: in instantiation of function template specialization 'boost::archive::load<boost::archive::text_iarchive, const boost::serialization::nvp<const A *const> >' requested here + archive::load(* this->This(), t); + ^ +../../../boost/archive/basic_text_iarchive.hpp:70:39: note: in instantiation of function template specialization 'boost::archive::detail::common_iarchive<boost::archive::text_iarchive>::load_override<const boost::serialization::nvp<const A *const> >' requested here + this->detail_common_iarchive::load_override(t); + ^ +../../../boost/archive/text_iarchive.hpp:82:39: note: in instantiation of function template specialization 'boost::archive::basic_text_iarchive<boost::archive::text_iarchive>::load_override<const boost::serialization::nvp<const A *const> >' requested here + basic_text_iarchive<Archive>::load_override(t); + ^ +../../../boost/archive/detail/interface_iarchive.hpp:68:23: note: in instantiation of function template specialization 'boost::archive::text_iarchive_impl<boost::archive::text_iarchive>::load_override<const boost::serialization::nvp<const A *const> >' requested here + this->This()->load_override(t); + ^ +test_const_load_fail3_nvp.cpp:23:8: note: in instantiation of function template specialization 'boost::archive::detail::interface_iarchive<boost::archive::text_iarchive>::operator>><const boost::serialization::nvp<const A *const> >' requested here + ia >> BOOST_SERIALIZATION_NVP(a); + ^ +../../../boost/archive/detail/iserializer.hpp:538:45: note: variable 't' declared const here + static void invoke(Archive & ar, Tptr & t){ + ~~~~~~~^ +2 errors generated. +(failed-as-expected) ../../../bin.v2/libs/serialization/test/test_const_load_fail3_nvp.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_const_load_fail3_nvp.o +**passed** ../../../bin.v2/libs/serialization/test/test_const_load_fail3_nvp.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_const_load_fail3_nvp.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_const_save_warn1.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_const_save_warn1.o +**passed** ../../../bin.v2/libs/serialization/test/test_const_save_warn1.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_const_save_warn1.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_check.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_check.o +In file included from test_check.cpp:18: +In file included from ../../../boost/archive/text_iarchive.hpp:24: +In file included from ../../../boost/archive/basic_text_iarchive.hpp:30: +In file included from ../../../boost/archive/detail/common_iarchive.hpp:23: +In file included from ../../../boost/archive/detail/interface_iarchive.hpp:22: +In file included from ../../../boost/archive/detail/iserializer.hpp:90: +../../../boost/archive/detail/check.hpp:78:5: error: implicit instantiation of undefined template 'boost::STATIC_ASSERTION_FAILURE<false>' + BOOST_STATIC_ASSERT(typex::value); + ^ +../../../boost/static_assert.hpp:154:13: note: expanded from macro 'BOOST_STATIC_ASSERT' + sizeof(::boost::STATIC_ASSERTION_FAILURE< BOOST_STATIC_ASSERT_BOOL_CAST( __VA_ARGS__ ) >)>\ + ^ +../../../boost/archive/detail/oserializer.hpp:314:9: note: in instantiation of function template specialization 'boost::archive::detail::check_object_versioning<check2>' requested here + check_object_versioning< T >(); + ^ +../../../boost/archive/detail/oserializer.hpp:539:12: note: in instantiation of function template specialization 'boost::archive::detail::save_non_pointer_type<boost::archive::text_oarchive>::invoke<check2>' requested here + typex::invoke(ar, t); + ^ +../../../boost/archive/detail/common_oarchive.hpp:71:18: note: in instantiation of function template specialization 'boost::archive::save<boost::archive::text_oarchive, const check2>' requested here + archive::save(* this->This(), t); + ^ +../../../boost/archive/basic_text_oarchive.hpp:83:39: note: in instantiation of function template specialization 'boost::archive::detail::common_oarchive<boost::archive::text_oarchive>::save_override<const check2>' requested here + this->detail_common_oarchive::save_override(t); + ^ +../../../boost/archive/detail/interface_oarchive.hpp:70:23: note: in instantiation of function template specialization 'boost::archive::basic_text_oarchive<boost::archive::text_oarchive>::save_override<const check2>' requested here + this->This()->save_override(t); + ^ +test_check.cpp:85:12: note: in instantiation of function template specialization 'boost::archive::detail::interface_oarchive<boost::archive::text_oarchive>::operator<<<check2>' requested here + oa << c2_out; // error check_object_versioning + ^ +../../../boost/static_assert.hpp:79:26: note: template is declared here +template <bool x> struct STATIC_ASSERTION_FAILURE; + ^ +In file included from test_check.cpp:18: +In file included from ../../../boost/archive/text_iarchive.hpp:24: +In file included from ../../../boost/archive/basic_text_iarchive.hpp:30: +In file included from ../../../boost/archive/detail/common_iarchive.hpp:23: +In file included from ../../../boost/archive/detail/interface_iarchive.hpp:22: +In file included from ../../../boost/archive/detail/iserializer.hpp:90: +../../../boost/archive/detail/check.hpp:162:5: error: implicit instantiation of undefined template 'boost::STATIC_ASSERTION_FAILURE<false>' + BOOST_STATIC_ASSERT(typex::value); + ^ +../../../boost/static_assert.hpp:154:13: note: expanded from macro 'BOOST_STATIC_ASSERT' + sizeof(::boost::STATIC_ASSERTION_FAILURE< BOOST_STATIC_ASSERT_BOOL_CAST( __VA_ARGS__ ) >)>\ + ^ +../../../boost/archive/detail/iserializer.hpp:609:13: note: in instantiation of function template specialization 'boost::archive::detail::check_const_loading<const check1>' requested here + detail::check_const_loading< T >(); + ^ +../../../boost/archive/detail/common_iarchive.hpp:67:18: note: in instantiation of function template specialization 'boost::archive::load<boost::archive::text_iarchive, const check1>' requested here + archive::load(* this->This(), t); + ^ +../../../boost/archive/basic_text_iarchive.hpp:70:39: note: in instantiation of function template specialization 'boost::archive::detail::common_iarchive<boost::archive::text_iarchive>::load_override<const check1>' requested here + this->detail_common_iarchive::load_override(t); + ^ +../../../boost/archive/text_iarchive.hpp:82:39: note: in instantiation of function template specialization 'boost::archive::basic_text_iarchive<boost::archive::text_iarchive>::load_override<const check1>' requested here + basic_text_iarchive<Archive>::load_override(t); + ^ +../../../boost/archive/detail/interface_iarchive.hpp:68:23: note: in instantiation of function template specialization 'boost::archive::text_iarchive_impl<boost::archive::text_iarchive>::load_override<const check1>' requested here + this->This()->load_override(t); + ^ +test_check.cpp:91:12: note: in instantiation of function template specialization 'boost::archive::detail::interface_iarchive<boost::archive::text_iarchive>::operator>><const check1>' requested here + ia >> c1_in; // check_const_loading + ^ +../../../boost/static_assert.hpp:79:26: note: template is declared here +template <bool x> struct STATIC_ASSERTION_FAILURE; + ^ +2 errors generated. +(failed-as-expected) ../../../bin.v2/libs/serialization/test/test_check.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_check.o +**passed** ../../../bin.v2/libs/serialization/test/test_check.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_check.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_const_save_warn2.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_const_save_warn2.o +**passed** ../../../bin.v2/libs/serialization/test/test_const_save_warn2.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_const_save_warn2.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_const_save_warn3.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_const_save_warn3.o +**passed** ../../../bin.v2/libs/serialization/test/test_const_save_warn3.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_const_save_warn3.test +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_const_pass.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_const_pass.o +clang-darwin.compile.c++ ../../../bin.v2/libs/serialization/test/test_traits_pass.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_traits_pass.o +**passed** ../../../bin.v2/libs/serialization/test/test_traits_pass.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_traits_pass.test +**passed** ../../../bin.v2/libs/serialization/test/test_const_pass.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_const_pass.test +...updated 1433 targets... diff --git a/src/boost/libs/serialization/test/base.hpp b/src/boost/libs/serialization/test/base.hpp new file mode 100644 index 00000000..853bbc18 --- /dev/null +++ b/src/boost/libs/serialization/test/base.hpp @@ -0,0 +1,46 @@ +#ifndef BOOST_SERIALIZATION_TEST_BASE_HPP +#define BOOST_SERIALIZATION_TEST_BASE_HPP + +// MS compatible compilers support #pragma once +#if defined(_MSC_VER) +# pragma once +#endif + +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// base.hpp simple class test + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <boost/config.hpp> + +#include <boost/serialization/access.hpp> +#include <boost/serialization/assume_abstract.hpp> +#include <boost/preprocessor/facilities/empty.hpp> + +#if defined(BASE_IMPORT) + #define DLL_DECL BOOST_SYMBOL_IMPORT +#elif defined(BASE_EXPORT) + #define DLL_DECL BOOST_SYMBOL_EXPORT +#else + #define DLL_DECL +#endif + +class DLL_DECL base +{ + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive & /* ar */, const unsigned int /* file_version */); +public: + virtual ~base(){}; +}; + +BOOST_SERIALIZATION_ASSUME_ABSTRACT(base) + +#undef DLL_DECL + +#endif // BOOST_SERIALIZATION_TEST_BASE_HPP diff --git a/src/boost/libs/serialization/test/binary_archive.hpp b/src/boost/libs/serialization/test/binary_archive.hpp new file mode 100644 index 00000000..b4dc63ea --- /dev/null +++ b/src/boost/libs/serialization/test/binary_archive.hpp @@ -0,0 +1,24 @@ +// (C) Copyright 2002-4 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. +// (C) Copyright 2002-4 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +// binary_archive +#include <boost/archive/binary_oarchive.hpp> +typedef boost::archive::binary_oarchive test_oarchive; +typedef std::ofstream test_ostream; + +#include <boost/archive/binary_iarchive.hpp> +typedef boost::archive::binary_iarchive test_iarchive; +typedef std::ifstream test_istream; + +//#define TEST_STREAM_FLAGS (std::ios::binary | std::ios::in | std::ios::out) +#define TEST_STREAM_FLAGS (std::ios::binary) diff --git a/src/boost/libs/serialization/test/binary_warchive.hpp b/src/boost/libs/serialization/test/binary_warchive.hpp new file mode 100644 index 00000000..929f3a37 --- /dev/null +++ b/src/boost/libs/serialization/test/binary_warchive.hpp @@ -0,0 +1,14 @@ +// (C) Copyright 2002-4 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. +// binary_warchive +#include <boost/archive/binary_woarchive.hpp> +typedef boost::archive::binary_woarchive test_oarchive; +typedef std::wofstream test_ostream; +#include <boost/archive/binary_wiarchive.hpp> +typedef boost::archive::binary_wiarchive test_iarchive; +typedef std::wifstream test_istream; +#define TEST_STREAM_FLAGS std::wios::binary diff --git a/src/boost/libs/serialization/test/config_test.cpp b/src/boost/libs/serialization/test/config_test.cpp new file mode 100644 index 00000000..98ce0ab8 --- /dev/null +++ b/src/boost/libs/serialization/test/config_test.cpp @@ -0,0 +1,17 @@ +#include "../../../boost/config.hpp" + +#if defined(__clang__) +#pragma message "__clang__ defined" +#endif + +#if defined(BOOST_CLANG) +#pragma message "BOOST_CLANG defined" +#endif + +#if defined(__GNUC__) +#pragma message "__GNUC__ defined" +#endif + +#include "../../../boost/mpl/print.hpp" + +typedef int x; diff --git a/src/boost/libs/serialization/test/config_test.o b/src/boost/libs/serialization/test/config_test.o Binary files differnew file mode 100644 index 00000000..8e708741 --- /dev/null +++ b/src/boost/libs/serialization/test/config_test.o diff --git a/src/boost/libs/serialization/test/derived2.hpp b/src/boost/libs/serialization/test/derived2.hpp new file mode 100644 index 00000000..4be59166 --- /dev/null +++ b/src/boost/libs/serialization/test/derived2.hpp @@ -0,0 +1,50 @@ +#ifndef BOOST_SERIALIZATION_TEST_DERIVED2_HPP +#define BOOST_SERIALIZATION_TEST_DERIVED2_HPP + +// MS compatible compilers support #pragma once +#if defined(_MSC_VER) +# pragma once +#endif + +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// derived2.hpp simple class test + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <boost/config.hpp> + +#include <boost/serialization/export.hpp> +#include <boost/serialization/access.hpp> + +#define BASE_IMPORT +#include "base.hpp" + +#if defined(DERIVED2_IMPORT) + #define DLL_DECL BOOST_SYMBOL_IMPORT +#elif defined(DERIVED2_EXPORT) + #define DLL_DECL BOOST_SYMBOL_EXPORT +#else + #define DLL_DECL +#endif + +class DLL_DECL derived2 : + public base +{ + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive &ar, const unsigned int /* file_version */); +public: + ~derived2(){} +}; + +#undef DLL_DECL + +// MWerks users can do this to make their code work +BOOST_SERIALIZATION_MWERKS_BASE_AND_DERIVED(base, derived2) + +#endif // BOOST_SERIALIZATION_TEST_DERIVED2_HPP diff --git a/src/boost/libs/serialization/test/dll_a.cpp b/src/boost/libs/serialization/test/dll_a.cpp new file mode 100644 index 00000000..6f9ab196 --- /dev/null +++ b/src/boost/libs/serialization/test/dll_a.cpp @@ -0,0 +1,49 @@ + +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// dll_a.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// Build a dll which contains the serialization for a class A +// used in testing distribution of serialization code in DLLS + +#define A_EXPORT +#include "A.hpp" +#include "A.ipp" +#include "A.cpp" + +// instantiate code for text archives + +#include <boost/archive/text_oarchive.hpp> +#include <boost/archive/text_iarchive.hpp> + +template +A_DLL_DECL void A::serialize( + boost::archive::text_oarchive &ar, + const unsigned int /* file_version */ +); +template +A_DLL_DECL void A::serialize( + boost::archive::text_iarchive &ar, + const unsigned int /* file_version */ +); + +// instantiate code for polymorphic archives + +#include <boost/archive/polymorphic_oarchive.hpp> +#include <boost/archive/polymorphic_iarchive.hpp> + +template +A_DLL_DECL void A::serialize( + boost::archive::polymorphic_oarchive &, + const unsigned int /* file_version */ +); +template +A_DLL_DECL void A::serialize( + boost::archive::polymorphic_iarchive &, + const unsigned int /* file_version */ +); + diff --git a/src/boost/libs/serialization/test/dll_base.cpp b/src/boost/libs/serialization/test/dll_base.cpp new file mode 100644 index 00000000..87645b4d --- /dev/null +++ b/src/boost/libs/serialization/test/dll_base.cpp @@ -0,0 +1,55 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// dll_base.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// Build a dll which contains the serialization for a class A +// used in testing distribution of serialization code in DLLS +#include <boost/serialization/export.hpp> + +#define BASE_EXPORT +#include "base.hpp" + +template<class Archive> +void base::serialize( + Archive &ar, + const unsigned int /* file_version */){ +} + +// for some reason this is required at least by MSVC +// given that its declared virtual .. = 0; This +// seems wrong to me but here it is. +//polymorphic_base::~polymorphic_base(){} + +// instantiate code for text archives +#include <boost/archive/text_oarchive.hpp> +#include <boost/archive/text_iarchive.hpp> + +// instantiate code for polymorphic archives +#include <boost/archive/polymorphic_oarchive.hpp> +#include <boost/archive/polymorphic_iarchive.hpp> + +// note: BOOST_CLASS_EXPORT cannot be used to instantiate +// serialization code for an abstract base class. So use +// explicit instantiation in this case. +//BOOST_CLASS_EXPORT(polymorphic_base) + +template BOOST_SYMBOL_EXPORT void base::serialize( + boost::archive::text_oarchive & ar, + const unsigned int version +); +template BOOST_SYMBOL_EXPORT void base::serialize( + boost::archive::text_iarchive & ar, + const unsigned int version +); +template BOOST_SYMBOL_EXPORT void base::serialize( + boost::archive::polymorphic_oarchive & ar, + const unsigned int version +); +template BOOST_SYMBOL_EXPORT void base::serialize( + boost::archive::polymorphic_iarchive & ar, + const unsigned int version +); diff --git a/src/boost/libs/serialization/test/dll_derived2.cpp b/src/boost/libs/serialization/test/dll_derived2.cpp new file mode 100644 index 00000000..e5757b3f --- /dev/null +++ b/src/boost/libs/serialization/test/dll_derived2.cpp @@ -0,0 +1,56 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// dll_derived2.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// Build a dll which contains the serialization for a class A +// used in testing distribution of serialization code in DLLS + +#include <boost/config.hpp> + +#include <boost/serialization/nvp.hpp> + +#define DERIVED2_EXPORT +#include "derived2.hpp" + +template<class Archive> +void derived2::serialize( + Archive &ar, + const unsigned int /* file_version */ +){ + ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(base); +} + +// instantiate code for text archives +#include <boost/archive/text_oarchive.hpp> +#include <boost/archive/text_iarchive.hpp> + +template BOOST_SYMBOL_EXPORT void derived2::serialize( + boost::archive::text_oarchive & ar, + const unsigned int version +); +template BOOST_SYMBOL_EXPORT void derived2::serialize( + boost::archive::text_iarchive & ar, + const unsigned int version +); + +#include <boost/archive/polymorphic_oarchive.hpp> +#include <boost/archive/polymorphic_iarchive.hpp> + +template BOOST_SYMBOL_EXPORT void derived2::serialize( + boost::archive::polymorphic_oarchive & ar, + const unsigned int version +); +template BOOST_SYMBOL_EXPORT void derived2::serialize( + boost::archive::polymorphic_iarchive & ar, + const unsigned int version +); + +// note: export has to be AFTER #includes for all archive classes + +#include <boost/serialization/factory.hpp> +BOOST_SERIALIZATION_FACTORY_0(derived2) +BOOST_CLASS_EXPORT(derived2) diff --git a/src/boost/libs/serialization/test/dll_polymorphic_base.cpp b/src/boost/libs/serialization/test/dll_polymorphic_base.cpp new file mode 100644 index 00000000..9d949b5e --- /dev/null +++ b/src/boost/libs/serialization/test/dll_polymorphic_base.cpp @@ -0,0 +1,12 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// dll_polymorphic_base.cpp + +// (C) Copyright 2018 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#define POLYMORPHIC_BASE_EXPORT +#include "polymorphic_base.cpp" diff --git a/src/boost/libs/serialization/test/dll_polymorphic_derived2.cpp b/src/boost/libs/serialization/test/dll_polymorphic_derived2.cpp new file mode 100644 index 00000000..e15d5f20 --- /dev/null +++ b/src/boost/libs/serialization/test/dll_polymorphic_derived2.cpp @@ -0,0 +1,13 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// polymorphic_derived2.cpp + +// (C) Copyright 2018Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#define POLYMORPHIC_BASE_IMPORT +#define POLYMORPHIC_DERIVED2_EXPORT +#include "polymorphic_derived2.cpp" diff --git a/src/boost/libs/serialization/test/library_status.html b/src/boost/libs/serialization/test/library_status.html new file mode 100644 index 00000000..e108a563 --- /dev/null +++ b/src/boost/libs/serialization/test/library_status.html @@ -0,0 +1,369 @@ +<html> +<head> +<title>Boost Library Status Automatic Test</title> +</head> +<body bgcolor="#ffffff" text="#000000"> +<table border="0"> +<h1>Library Status: serialization/test</h1> +<b>Run Date:</b> 21:44:22 UTC, Friday 11 October 2019 +<br></td> +</table> +<br> +<table border="1" cellspacing="0" cellpadding="5"> +<tr> +<td rowspan="4">Test Name</td> +<td align="center" >clang-darwin-03</td> +</tr><tr> +<td align="center" >debug</td> +</tr><tr> +<td align="center" >threading-multi</td> +</tr><tr> +<td align="center" >visibility-hidden</td> +</tr><tr><td>test_array_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_array_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_array_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_array_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_array_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_binary_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_binary_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_binary_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_binary_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_binary_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_bitset_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_bitset_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_bitset_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_bitset_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_bitset_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_boost_array_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_boost_array_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_boost_array_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_boost_array_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_boost_array_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_check</td><td align="right"><a href="links.html#bin.v2/libs/serialization/test/test_check.test/clang-darwin-03/debug/threading-multi/visibility-hidden"><i>Warn</i></a></td></tr> +<tr><td>test_class_info_load_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_class_info_load_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_class_info_load_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_class_info_load_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_class_info_load_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_class_info_save_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_class_info_save_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_class_info_save_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_class_info_save_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_class_info_save_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_codecvt_null</td><td align="right">Pass</td></tr> +<tr><td>test_complex_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_complex_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_complex_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_complex_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_complex_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_const_load_fail1</td><td align="right"><a href="links.html#bin.v2/libs/serialization/test/test_const_load_fail1.test/clang-darwin-03/debug/threading-multi/visibility-hidden"><i>Warn</i></a></td></tr> +<tr><td>test_const_load_fail1_nvp</td><td align="right"><a href="links.html#bin.v2/libs/serialization/test/test_const_load_fail1_nvp.test/clang-darwin-03/debug/threading-multi/visibility-hidden"><i>Warn</i></a></td></tr> +<tr><td>test_const_load_fail2</td><td align="right"><a href="links.html#bin.v2/libs/serialization/test/test_const_load_fail2.test/clang-darwin-03/debug/threading-multi/visibility-hidden"><i>Warn</i></a></td></tr> +<tr><td>test_const_load_fail2_nvp</td><td align="right"><a href="links.html#bin.v2/libs/serialization/test/test_const_load_fail2_nvp.test/clang-darwin-03/debug/threading-multi/visibility-hidden"><i>Warn</i></a></td></tr> +<tr><td>test_const_load_fail3</td><td align="right"><a href="links.html#bin.v2/libs/serialization/test/test_const_load_fail3.test/clang-darwin-03/debug/threading-multi/visibility-hidden"><i>Warn</i></a></td></tr> +<tr><td>test_const_load_fail3_nvp</td><td align="right"><a href="links.html#bin.v2/libs/serialization/test/test_const_load_fail3_nvp.test/clang-darwin-03/debug/threading-multi/visibility-hidden"><i>Warn</i></a></td></tr> +<tr><td>test_const_pass</td><td align="right">Pass</td></tr> +<tr><td>test_const_save_warn1</td><td align="right">Pass</td></tr> +<tr><td>test_const_save_warn2</td><td align="right">Pass</td></tr> +<tr><td>test_const_save_warn3</td><td align="right">Pass</td></tr> +<tr><td>test_contained_class_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_contained_class_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_contained_class_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_contained_class_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_contained_class_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_cyclic_ptrs_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_cyclic_ptrs_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_cyclic_ptrs_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_cyclic_ptrs_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_cyclic_ptrs_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_delete_pointer_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_delete_pointer_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_delete_pointer_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_delete_pointer_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_delete_pointer_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_deque_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_deque_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_deque_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_deque_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_deque_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_derived_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_derived_class_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_derived_class_ptr_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_derived_class_ptr_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_derived_class_ptr_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_derived_class_ptr_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_derived_class_ptr_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_derived_class_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_derived_class_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_derived_class_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_derived_class_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_derived_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_derived_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_derived_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_derived_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_diamond_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_diamond_complex_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_diamond_complex_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_diamond_complex_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_diamond_complex_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_diamond_complex_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_diamond_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_diamond_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_diamond_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_diamond_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_dll_exported_polymorphic_binary_archive</td><td align="right"><a href="links.html#bin.v2/libs/serialization/test/test_dll_exported_polymorphic_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden"><i>Warn</i></a></td></tr> +<tr><td>test_dll_exported_polymorphic_text_archive</td><td align="right"><a href="links.html#bin.v2/libs/serialization/test/test_dll_exported_polymorphic_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden"><i>Warn</i></a></td></tr> +<tr><td>test_dll_exported_polymorphic_text_warchive</td><td align="right"><a href="links.html#bin.v2/libs/serialization/test/test_dll_exported_polymorphic_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden"><i>Warn</i></a></td></tr> +<tr><td>test_dll_exported_polymorphic_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_dll_exported_polymorphic_xml_warchive</td><td align="right"><a href="links.html#bin.v2/libs/serialization/test/test_dll_exported_polymorphic_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden"><i>Warn</i></a></td></tr> +<tr><td>test_dll_simple</td><td align="right"><a href="links.html#bin.v2/libs/serialization/test/test_dll_simple.test/clang-darwin-03/debug/threading-multi/visibility-hidden"><i>Warn</i></a></td></tr> +<tr><td>test_exported_polymorphic_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_exported_polymorphic_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_exported_polymorphic_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_exported_polymorphic_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_exported_polymorphic_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_forward_list_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_forward_list_ptrs_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_forward_list_ptrs_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_forward_list_ptrs_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_forward_list_ptrs_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_forward_list_ptrs_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_forward_list_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_forward_list_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_forward_list_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_forward_list_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_helper_support_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_helper_support_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_helper_support_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_helper_support_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_helper_support_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_inclusion2</td><td align="right">Pass</td></tr> +<tr><td>test_inclusion</td><td align="right">Pass</td></tr> +<tr><td>test_interrupts_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_interrupts_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_interrupts_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_interrupts_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_interrupts_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_iterators</td><td align="right">Pass</td></tr> +<tr><td>test_iterators_base64</td><td align="right">Pass</td></tr> +<tr><td>test_list_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_list_ptrs_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_list_ptrs_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_list_ptrs_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_list_ptrs_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_list_ptrs_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_list_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_list_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_list_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_list_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_map_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_map_boost_unordered_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_map_boost_unordered_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_map_boost_unordered_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_map_boost_unordered_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_map_boost_unordered_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_map_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_map_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_map_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_map_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_mi_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_mi_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_mi_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_mi_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_mi_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_mult_archive_types</td><td align="right">Pass</td></tr> +<tr><td>test_multiple_inheritance_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_multiple_inheritance_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_multiple_inheritance_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_multiple_inheritance_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_multiple_inheritance_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_multiple_ptrs_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_multiple_ptrs_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_multiple_ptrs_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_multiple_ptrs_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_multiple_ptrs_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_native_array_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_native_array_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_native_array_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_native_array_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_native_array_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_new_operator_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_new_operator_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_new_operator_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_new_operator_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_new_operator_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_no_rtti_polymorphic_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_no_rtti_polymorphic_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_no_rtti_polymorphic_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_no_rtti_polymorphic_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_no_rtti_polymorphic_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_non_default_ctor2_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_non_default_ctor2_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_non_default_ctor2_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_non_default_ctor2_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_non_default_ctor2_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_non_default_ctor_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_non_default_ctor_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_non_default_ctor_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_non_default_ctor_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_non_default_ctor_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_non_intrusive_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_non_intrusive_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_non_intrusive_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_non_intrusive_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_non_intrusive_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_not_serializable</td><td align="right"><a href="links.html#bin.v2/libs/serialization/test/test_not_serializable.test/clang-darwin-03/debug/threading-multi/visibility-hidden"><i>Warn</i></a></td></tr> +<tr><td>test_null_ptr_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_null_ptr_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_null_ptr_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_null_ptr_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_null_ptr_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_nvp_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_nvp_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_nvp_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_nvp_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_nvp_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_object_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_object_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_object_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_object_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_object_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_optional_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_optional_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_optional_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_optional_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_optional_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_p_helper_polymorphic_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_p_helper_polymorphic_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_p_helper_polymorphic_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_p_helper_polymorphic_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_p_helper_polymorphic_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_polymorphic2_polymorphic_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_polymorphic2_polymorphic_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_polymorphic2_polymorphic_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_polymorphic2_polymorphic_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_polymorphic2_polymorphic_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_polymorphic_helper_polymorphic_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_polymorphic_helper_polymorphic_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_polymorphic_helper_polymorphic_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_polymorphic_helper_polymorphic_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_polymorphic_helper_polymorphic_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_polymorphic_polymorphic_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_polymorphic_polymorphic_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_polymorphic_polymorphic_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_polymorphic_polymorphic_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_polymorphic_polymorphic_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_primitive_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_primitive_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_primitive_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_primitive_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_primitive_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_priority_queue_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_priority_queue_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_priority_queue_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_priority_queue_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_priority_queue_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_private_ctor</td><td align="right">Pass</td></tr> +<tr><td>test_queue_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_queue_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_queue_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_queue_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_queue_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_recursion_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_recursion_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_recursion_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_recursion_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_recursion_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_registered_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_registered_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_registered_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_registered_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_registered_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_reset_object_address</td><td align="right">Pass</td></tr> +<tr><td>test_set_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_set_boost_unordered_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_set_boost_unordered_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_set_boost_unordered_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_set_boost_unordered_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_set_boost_unordered_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_set_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_set_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_set_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_set_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_shared_ptr_132_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_shared_ptr_132_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_shared_ptr_132_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_shared_ptr_132_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_shared_ptr_132_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_shared_ptr_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_shared_ptr_multi_base_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_shared_ptr_multi_base_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_shared_ptr_multi_base_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_shared_ptr_multi_base_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_shared_ptr_multi_base_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_shared_ptr_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_shared_ptr_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_shared_ptr_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_shared_ptr_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_simple_class_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_simple_class_ptr_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_simple_class_ptr_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_simple_class_ptr_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_simple_class_ptr_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_simple_class_ptr_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_simple_class_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_simple_class_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_simple_class_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_simple_class_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_singleton</td><td align="right">Pass</td></tr> +<tr><td>test_singleton_inherited</td><td align="right"><a href="links.html#bin.v2/libs/serialization/test/test_singleton_inherited.test/clang-darwin-03/debug/threading-multi/visibility-hidden"><i>Warn</i></a></td></tr> +<tr><td>test_singleton_plain</td><td align="right"><a href="links.html#bin.v2/libs/serialization/test/test_singleton_plain.test/clang-darwin-03/debug/threading-multi/visibility-hidden"><i>Warn</i></a></td></tr> +<tr><td>test_smart_cast</td><td align="right"><a href="links.html#bin.v2/libs/serialization/test/test_smart_cast.test/clang-darwin-03/debug/threading-multi/visibility-hidden"><i>Warn</i></a></td></tr> +<tr><td>test_split_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_split_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_split_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_split_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_split_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_stack_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_stack_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_stack_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_stack_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_stack_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_static_warning</td><td align="right">Pass</td></tr> +<tr><td>test_strong_typedef</td><td align="right">Pass</td></tr> +<tr><td>test_tracking_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_tracking_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_tracking_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_tracking_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_tracking_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_traits_fail</td><td align="right"><a href="links.html#bin.v2/libs/serialization/test/test_traits_fail.test/clang-darwin-03/debug/threading-multi/visibility-hidden"><i>Warn</i></a></td></tr> +<tr><td>test_traits_pass</td><td align="right">Pass</td></tr> +<tr><td>test_unique_ptr_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_unique_ptr_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_unique_ptr_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_unique_ptr_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_unique_ptr_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_unregistered_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_unregistered_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_unregistered_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_unregistered_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_unregistered_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_valarray_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_valarray_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_valarray_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_valarray_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_valarray_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_variant_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_variant_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_variant_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_variant_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_variant_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_vector_binary_archive</td><td align="right">Pass</td></tr> +<tr><td>test_vector_text_archive</td><td align="right">Pass</td></tr> +<tr><td>test_vector_text_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_vector_xml_archive</td><td align="right">Pass</td></tr> +<tr><td>test_vector_xml_warchive</td><td align="right">Pass</td></tr> +<tr><td>test_void_cast</td><td align="right"><a href="links.html#bin.v2/libs/serialization/test/test_void_cast.test/clang-darwin-03/debug/threading-multi/visibility-hidden"><i>Warn</i></a></td></tr> +</table> +</body> +</html> diff --git a/src/boost/libs/serialization/test/links.html b/src/boost/libs/serialization/test/links.html new file mode 100644 index 00000000..2356ba5b --- /dev/null +++ b/src/boost/libs/serialization/test/links.html @@ -0,0 +1,748 @@ +<html> +<head> +<title>Boost Library Status Error Log</title> +</head> +<body bgcolor="#ffffff" text="#000000"> +<table border="0"> +<h1>Library Status: serialization/test</h1> +<b>Run Date:</b> 21:44:22 UTC, Friday 11 October 2019 +<br></table> +<br> +<h2><a name="bin.v2/libs/serialization/test/test_check.test/clang-darwin-03/debug/threading-multi/visibility-hidden">bin.v2/libs/serialization/test/test_check.test/clang-darwin-03/debug/threading-multi/visibility-hidden</a></h2> +<h3>Compiler output:</h3><pre> +In file included from test_check.cpp:18: +In file included from ../../../boost/archive/text_iarchive.hpp:24: +In file included from ../../../boost/archive/basic_text_iarchive.hpp:30: +In file included from ../../../boost/archive/detail/common_iarchive.hpp:23: +In file included from ../../../boost/archive/detail/interface_iarchive.hpp:22: +In file included from ../../../boost/archive/detail/iserializer.hpp:90: +../../../boost/archive/detail/check.hpp:78:5: error: implicit instantiation of undefined template 'boost::STATIC_ASSERTION_FAILURE&lt;false&gt;' + BOOST_STATIC_ASSERT(typex::value); + ^ +../../../boost/static_assert.hpp:154:13: note: expanded from macro 'BOOST_STATIC_ASSERT' + sizeof(::boost::STATIC_ASSERTION_FAILURE&lt; BOOST_STATIC_ASSERT_BOOL_CAST( __VA_ARGS__ ) &gt;)&gt;\ + ^ +../../../boost/archive/detail/oserializer.hpp:314:9: note: in instantiation of function template specialization 'boost::archive::detail::check_object_versioning&lt;check2&gt;' requested here + check_object_versioning&lt; T &gt;(); + ^ +../../../boost/archive/detail/oserializer.hpp:539:12: note: in instantiation of function template specialization 'boost::archive::detail::save_non_pointer_type&lt;boost::archive::text_oarchive&gt;::invoke&lt;check2&gt;' requested here + typex::invoke(ar, t); + ^ +../../../boost/archive/detail/common_oarchive.hpp:71:18: note: in instantiation of function template specialization 'boost::archive::save&lt;boost::archive::text_oarchive, const check2&gt;' requested here + archive::save(* this-&gt;This(), t); + ^ +../../../boost/archive/basic_text_oarchive.hpp:83:39: note: in instantiation of function template specialization 'boost::archive::detail::common_oarchive&lt;boost::archive::text_oarchive&gt;::save_override&lt;const check2&gt;' requested here + this-&gt;detail_common_oarchive::save_override(t); + ^ +../../../boost/archive/detail/interface_oarchive.hpp:70:23: note: in instantiation of function template specialization 'boost::archive::basic_text_oarchive&lt;boost::archive::text_oarchive&gt;::save_override&lt;const check2&gt;' requested here + this-&gt;This()-&gt;save_override(t); + ^ +test_check.cpp:85:12: note: in instantiation of function template specialization 'boost::archive::detail::interface_oarchive&lt;boost::archive::text_oarchive&gt;::operator&lt;&lt;&lt;check2&gt;' requested here + oa &lt;&lt; c2_out; // error check_object_versioning + ^ +../../../boost/static_assert.hpp:79:26: note: template is declared here +template &lt;bool x&gt; struct STATIC_ASSERTION_FAILURE; + ^ +In file included from test_check.cpp:18: +In file included from ../../../boost/archive/text_iarchive.hpp:24: +In file included from ../../../boost/archive/basic_text_iarchive.hpp:30: +In file included from ../../../boost/archive/detail/common_iarchive.hpp:23: +In file included from ../../../boost/archive/detail/interface_iarchive.hpp:22: +In file included from ../../../boost/archive/detail/iserializer.hpp:90: +../../../boost/archive/detail/check.hpp:162:5: error: implicit instantiation of undefined template 'boost::STATIC_ASSERTION_FAILURE&lt;false&gt;' + BOOST_STATIC_ASSERT(typex::value); + ^ +../../../boost/static_assert.hpp:154:13: note: expanded from macro 'BOOST_STATIC_ASSERT' + sizeof(::boost::STATIC_ASSERTION_FAILURE&lt; BOOST_STATIC_ASSERT_BOOL_CAST( __VA_ARGS__ ) &gt;)&gt;\ + ^ +../../../boost/archive/detail/iserializer.hpp:609:13: note: in instantiation of function template specialization 'boost::archive::detail::check_const_loading&lt;const check1&gt;' requested here + detail::check_const_loading&lt; T &gt;(); + ^ +../../../boost/archive/detail/common_iarchive.hpp:67:18: note: in instantiation of function template specialization 'boost::archive::load&lt;boost::archive::text_iarchive, const check1&gt;' requested here + archive::load(* this-&gt;This(), t); + ^ +../../../boost/archive/basic_text_iarchive.hpp:70:39: note: in instantiation of function template specialization 'boost::archive::detail::common_iarchive&lt;boost::archive::text_iarchive&gt;::load_override&lt;const check1&gt;' requested here + this-&gt;detail_common_iarchive::load_override(t); + ^ +../../../boost/archive/text_iarchive.hpp:82:39: note: in instantiation of function template specialization 'boost::archive::basic_text_iarchive&lt;boost::archive::text_iarchive&gt;::load_override&lt;const check1&gt;' requested here + basic_text_iarchive&lt;Archive&gt;::load_override(t); + ^ +../../../boost/archive/detail/interface_iarchive.hpp:68:23: note: in instantiation of function template specialization 'boost::archive::text_iarchive_impl&lt;boost::archive::text_iarchive&gt;::load_override&lt;const check1&gt;' requested here + this-&gt;This()-&gt;load_override(t); + ^ +test_check.cpp:91:12: note: in instantiation of function template specialization 'boost::archive::detail::interface_iarchive&lt;boost::archive::text_iarchive&gt;::operator&gt;&gt;&lt;const check1&gt;' requested here + ia &gt;&gt; c1_in; // check_const_loading + ^ +../../../boost/static_assert.hpp:79:26: note: template is declared here +template &lt;bool x&gt; struct STATIC_ASSERTION_FAILURE; + ^ +2 errors generated. +(failed-as-expected) ../../../bin.v2/libs/serialization/test/test_check.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_check.o +</pre> +<h2><a name="bin.v2/libs/serialization/test/test_dll_exported_polymorphic_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden">bin.v2/libs/serialization/test/test_dll_exported_polymorphic_xml_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden</a></h2> +<h3>Compiler output:</h3><pre> +In file included from test_dll_exported.cpp:51: +./polymorphic_base.hpp:29:13: warning: polymorphic_base imported [-W#pragma-messages] + #pragma message ("polymorphic_base imported") + ^ +In file included from test_dll_exported.cpp:56: +./polymorphic_derived2.hpp:29:13: warning: polymorphic_derived2 imported [-W#pragma-messages] + #pragma message ("polymorphic_derived2 imported") + ^ +2 warnings generated. +</pre> +<h2><a name="bin.v2/libs/serialization/test/test_not_serializable.test/clang-darwin-03/debug/threading-multi/visibility-hidden">bin.v2/libs/serialization/test/test_not_serializable.test/clang-darwin-03/debug/threading-multi/visibility-hidden</a></h2> +<h3>Compiler output:</h3><pre> +In file included from test_not_serializable.cpp:14: +In file included from ./test_tools.hpp:246: +In file included from ./text_archive.hpp:8: +In file included from ../../../boost/archive/text_oarchive.hpp:31: +In file included from ../../../boost/archive/basic_text_oarchive.hpp:29: +In file included from ../../../boost/archive/detail/common_oarchive.hpp:22: +In file included from ../../../boost/archive/detail/interface_oarchive.hpp:23: +In file included from ../../../boost/archive/detail/oserializer.hpp:40: +In file included from ../../../boost/serialization/extended_type_info_typeid.hpp:37: +../../../boost/serialization/access.hpp:116:11: error: no member named 'serialize' in 'A' + t.serialize(ar, file_version); + ~ ^ +../../../boost/serialization/serialization.hpp:68:13: note: in instantiation of function template specialization 'boost::serialization::access::serialize&lt;boost::archive::text_oarchive, A&gt;' requested here + access::serialize(ar, t, static_cast&lt;unsigned int&gt;(file_version)); + ^ +../../../boost/serialization/serialization.hpp:126:5: note: in instantiation of function template specialization 'boost::serialization::serialize&lt;boost::archive::text_oarchive, A&gt;' requested here + serialize(ar, t, v); + ^ +../../../boost/archive/detail/oserializer.hpp:153:27: note: in instantiation of function template specialization 'boost::serialization::serialize_adl&lt;boost::archive::text_oarchive, A&gt;' requested here + boost::serialization::serialize_adl( + ^ +../../../boost/serialization/singleton.hpp:147:5: note: in instantiation of member function 'boost::archive::detail::oserializer&lt;boost::archive::text_oarchive, A&gt;::save_object_data' requested here + singleton_wrapper(){ + ^ +../../../boost/serialization/singleton.hpp:171:47: note: in instantiation of member function 'boost::serialization::detail::singleton_wrapper&lt;boost::archive::detail::oserializer&lt;boost::archive::text_oarchive, A&gt; &gt;::singleton_wrapper' requested here + static detail::singleton_wrapper&lt; T &gt; t; + ^ +../../../boost/serialization/singleton.hpp:196:16: note: (skipping 15 contexts in backtrace; use -ftemplate-backtrace-limit=0 to see all) + return get_instance(); + ^ +../../../boost/archive/detail/oserializer.hpp:539:12: note: in instantiation of function template specialization 'boost::archive::detail::save_non_pointer_type&lt;boost::archive::text_oarchive&gt;::invoke&lt;boost::serialization::nvp&lt;A&gt; &gt;' requested here + typex::invoke(ar, t); + ^ +../../../boost/archive/detail/common_oarchive.hpp:71:18: note: in instantiation of function template specialization 'boost::archive::save&lt;boost::archive::text_oarchive, const boost::serialization::nvp&lt;A&gt; &gt;' requested here + archive::save(* this-&gt;This(), t); + ^ +../../../boost/archive/basic_text_oarchive.hpp:83:39: note: in instantiation of function template specialization 'boost::archive::detail::common_oarchive&lt;boost::archive::text_oarchive&gt;::save_override&lt;const boost::serialization::nvp&lt;A&gt; &gt;' requested here + this-&gt;detail_common_oarchive::save_override(t); + ^ +../../../boost/archive/detail/interface_oarchive.hpp:70:23: note: in instantiation of function template specialization 'boost::archive::basic_text_oarchive&lt;boost::archive::text_oarchive&gt;::save_override&lt;const boost::serialization::nvp&lt;A&gt; &gt;' requested here + this-&gt;This()-&gt;save_override(t); + ^ +test_not_serializable.cpp:28:8: note: in instantiation of function template specialization 'boost::archive::detail::interface_oarchive&lt;boost::archive::text_oarchive&gt;::operator&lt;&lt;&lt;boost::serialization::nvp&lt;A&gt; &gt;' requested here + oa &lt;&lt; BOOST_SERIALIZATION_NVP(a); + ^ +In file included from test_not_serializable.cpp:14: +In file included from ./test_tools.hpp:246: +In file included from ./text_archive.hpp:8: +In file included from ../../../boost/archive/text_oarchive.hpp:31: +In file included from ../../../boost/archive/basic_text_oarchive.hpp:29: +In file included from ../../../boost/archive/detail/common_oarchive.hpp:22: +In file included from ../../../boost/archive/detail/interface_oarchive.hpp:23: +In file included from ../../../boost/archive/detail/oserializer.hpp:70: +../../../boost/archive/detail/check.hpp:60:5: error: implicit instantiation of undefined template 'boost::STATIC_ASSERTION_FAILURE&lt;false&gt;' + BOOST_STATIC_ASSERT(typex::value); + ^ +../../../boost/static_assert.hpp:154:13: note: expanded from macro 'BOOST_STATIC_ASSERT' + sizeof(::boost::STATIC_ASSERTION_FAILURE&lt; BOOST_STATIC_ASSERT_BOOL_CAST( __VA_ARGS__ ) &gt;)&gt;\ + ^ +../../../boost/archive/detail/iserializer.hpp:460:9: note: in instantiation of function template specialization 'boost::archive::detail::check_object_level&lt;A&gt;' requested here + check_object_level&lt; T &gt;(); + ^ +../../../boost/archive/detail/iserializer.hpp:624:12: note: in instantiation of function template specialization 'boost::archive::detail::load_non_pointer_type&lt;boost::archive::text_iarchive&gt;::invoke&lt;A&gt;' requested here + typex::invoke(ar, t); + ^ +../../../boost/archive/detail/common_iarchive.hpp:67:18: note: in instantiation of function template specialization 'boost::archive::load&lt;boost::archive::text_iarchive, A&gt;' requested here + archive::load(* this-&gt;This(), t); + ^ +../../../boost/archive/basic_text_iarchive.hpp:70:39: note: in instantiation of function template specialization 'boost::archive::detail::common_iarchive&lt;boost::archive::text_iarchive&gt;::load_override&lt;A&gt;' requested here + this-&gt;detail_common_iarchive::load_override(t); + ^ +../../../boost/archive/text_iarchive.hpp:82:39: note: in instantiation of function template specialization 'boost::archive::basic_text_iarchive&lt;boost::archive::text_iarchive&gt;::load_override&lt;A&gt;' requested here + basic_text_iarchive&lt;Archive&gt;::load_override(t); + ^ +../../../boost/archive/detail/interface_iarchive.hpp:68:23: note: (skipping 9 contexts in backtrace; use -ftemplate-backtrace-limit=0 to see all) + this-&gt;This()-&gt;load_override(t); + ^ +../../../boost/archive/detail/common_iarchive.hpp:67:18: note: in instantiation of function template specialization 'boost::archive::load&lt;boost::archive::text_iarchive, const boost::serialization::nvp&lt;A&gt; &gt;' requested here + archive::load(* this-&gt;This(), t); + ^ +../../../boost/archive/basic_text_iarchive.hpp:70:39: note: in instantiation of function template specialization 'boost::archive::detail::common_iarchive&lt;boost::archive::text_iarchive&gt;::load_override&lt;const boost::serialization::nvp&lt;A&gt; &gt;' requested here + this-&gt;detail_common_iarchive::load_override(t); + ^ +../../../boost/archive/text_iarchive.hpp:82:39: note: in instantiation of function template specialization 'boost::archive::basic_text_iarchive&lt;boost::archive::text_iarchive&gt;::load_override&lt;const boost::serialization::nvp&lt;A&gt; &gt;' requested here + basic_text_iarchive&lt;Archive&gt;::load_override(t); + ^ +../../../boost/archive/detail/interface_iarchive.hpp:68:23: note: in instantiation of function template specialization 'boost::archive::text_iarchive_impl&lt;boost::archive::text_iarchive&gt;::load_override&lt;const boost::serialization::nvp&lt;A&gt; &gt;' requested here + this-&gt;This()-&gt;load_override(t); + ^ +test_not_serializable.cpp:35:8: note: in instantiation of function template specialization 'boost::archive::detail::interface_iarchive&lt;boost::archive::text_iarchive&gt;::operator&gt;&gt;&lt;const boost::serialization::nvp&lt;A&gt; &gt;' requested here + ia &gt;&gt; BOOST_SERIALIZATION_NVP(a); + ^ +../../../boost/static_assert.hpp:79:26: note: template is declared here +template &lt;bool x&gt; struct STATIC_ASSERTION_FAILURE; + ^ +In file included from test_not_serializable.cpp:14: +In file included from ./test_tools.hpp:246: +In file included from ./text_archive.hpp:8: +In file included from ../../../boost/archive/text_oarchive.hpp:31: +In file included from ../../../boost/archive/basic_text_oarchive.hpp:29: +In file included from ../../../boost/archive/detail/common_oarchive.hpp:22: +In file included from ../../../boost/archive/detail/interface_oarchive.hpp:23: +In file included from ../../../boost/archive/detail/oserializer.hpp:40: +In file included from ../../../boost/serialization/extended_type_info_typeid.hpp:37: +../../../boost/serialization/access.hpp:116:11: error: no member named 'serialize' in 'A' + t.serialize(ar, file_version); + ~ ^ +../../../boost/serialization/serialization.hpp:68:13: note: in instantiation of function template specialization 'boost::serialization::access::serialize&lt;boost::archive::text_iarchive, A&gt;' requested here + access::serialize(ar, t, static_cast&lt;unsigned int&gt;(file_version)); + ^ +../../../boost/serialization/serialization.hpp:126:5: note: in instantiation of function template specialization 'boost::serialization::serialize&lt;boost::archive::text_iarchive, A&gt;' requested here + serialize(ar, t, v); + ^ +../../../boost/archive/detail/iserializer.hpp:187:27: note: in instantiation of function template specialization 'boost::serialization::serialize_adl&lt;boost::archive::text_iarchive, A&gt;' requested here + boost::serialization::serialize_adl( + ^ +../../../boost/serialization/singleton.hpp:147:5: note: in instantiation of member function 'boost::archive::detail::iserializer&lt;boost... + (remainder deleted because of excessive size) +</pre> +<h2><a name="bin.v2/libs/serialization/test/test_const_load_fail2.test/clang-darwin-03/debug/threading-multi/visibility-hidden">bin.v2/libs/serialization/test/test_const_load_fail2.test/clang-darwin-03/debug/threading-multi/visibility-hidden</a></h2> +<h3>Compiler output:</h3><pre> +In file included from test_const_load_fail2.cpp:11: +In file included from ../../../boost/archive/text_iarchive.hpp:24: +In file included from ../../../boost/archive/basic_text_iarchive.hpp:30: +In file included from ../../../boost/archive/detail/common_iarchive.hpp:23: +In file included from ../../../boost/archive/detail/interface_iarchive.hpp:22: +In file included from ../../../boost/archive/detail/iserializer.hpp:90: +../../../boost/archive/detail/check.hpp:162:5: error: implicit instantiation of undefined template 'boost::STATIC_ASSERTION_FAILURE&lt;false&gt;' + BOOST_STATIC_ASSERT(typex::value); + ^ +../../../boost/static_assert.hpp:154:13: note: expanded from macro 'BOOST_STATIC_ASSERT' + sizeof(::boost::STATIC_ASSERTION_FAILURE&lt; BOOST_STATIC_ASSERT_BOOL_CAST( __VA_ARGS__ ) &gt;)&gt;\ + ^ +../../../boost/archive/detail/iserializer.hpp:609:13: note: in instantiation of function template specialization 'boost::archive::detail::check_const_loading&lt;A *const&gt;' requested here + detail::check_const_loading&lt; T &gt;(); + ^ +../../../boost/archive/detail/common_iarchive.hpp:67:18: note: in instantiation of function template specialization 'boost::archive::load&lt;boost::archive::text_iarchive, A *const&gt;' requested here + archive::load(* this-&gt;This(), t); + ^ +../../../boost/archive/basic_text_iarchive.hpp:70:39: note: in instantiation of function template specialization 'boost::archive::detail::common_iarchive&lt;boost::archive::text_iarchive&gt;::load_override&lt;A *const&gt;' requested here + this-&gt;detail_common_iarchive::load_override(t); + ^ +../../../boost/archive/text_iarchive.hpp:82:39: note: in instantiation of function template specialization 'boost::archive::basic_text_iarchive&lt;boost::archive::text_iarchive&gt;::load_override&lt;A *const&gt;' requested here + basic_text_iarchive&lt;Archive&gt;::load_override(t); + ^ +../../../boost/archive/detail/interface_iarchive.hpp:68:23: note: in instantiation of function template specialization 'boost::archive::text_iarchive_impl&lt;boost::archive::text_iarchive&gt;::load_override&lt;A *const&gt;' requested here + this-&gt;This()-&gt;load_override(t); + ^ +test_const_load_fail2.cpp:22:8: note: in instantiation of function template specialization 'boost::archive::detail::interface_iarchive&lt;boost::archive::text_iarchive&gt;::operator&gt;&gt;&lt;A *const&gt;' requested here + ia &gt;&gt; a; + ^ +../../../boost/static_assert.hpp:79:26: note: template is declared here +template &lt;bool x&gt; struct STATIC_ASSERTION_FAILURE; + ^ +In file included from test_const_load_fail2.cpp:11: +In file included from ../../../boost/archive/text_iarchive.hpp:24: +In file included from ../../../boost/archive/basic_text_iarchive.hpp:30: +In file included from ../../../boost/archive/detail/common_iarchive.hpp:23: +In file included from ../../../boost/archive/detail/interface_iarchive.hpp:22: +../../../boost/archive/detail/iserializer.hpp:552:15: error: cannot assign to variable 't' with const-qualified type 'A *const &amp;' + t = pointer_tweak(newbpis_ptr-&gt;get_eti(), t, *t); + ~ ^ +../../../boost/archive/detail/iserializer.hpp:624:12: note: in instantiation of function template specialization 'boost::archive::detail::load_pointer_type&lt;boost::archive::text_iarchive&gt;::invoke&lt;A *const&gt;' requested here + typex::invoke(ar, t); + ^ +../../../boost/archive/detail/common_iarchive.hpp:67:18: note: in instantiation of function template specialization 'boost::archive::load&lt;boost::archive::text_iarchive, A *const&gt;' requested here + archive::load(* this-&gt;This(), t); + ^ +../../../boost/archive/basic_text_iarchive.hpp:70:39: note: in instantiation of function template specialization 'boost::archive::detail::common_iarchive&lt;boost::archive::text_iarchive&gt;::load_override&lt;A *const&gt;' requested here + this-&gt;detail_common_iarchive::load_override(t); + ^ +../../../boost/archive/text_iarchive.hpp:82:39: note: in instantiation of function template specialization 'boost::archive::basic_text_iarchive&lt;boost::archive::text_iarchive&gt;::load_override&lt;A *const&gt;' requested here + basic_text_iarchive&lt;Archive&gt;::load_override(t); + ^ +../../../boost/archive/detail/interface_iarchive.hpp:68:23: note: in instantiation of function template specialization 'boost::archive::text_iarchive_impl&lt;boost::archive::text_iarchive&gt;::load_override&lt;A *const&gt;' requested here + this-&gt;This()-&gt;load_override(t); + ^ +test_const_load_fail2.cpp:22:8: note: in instantiation of function template specialization 'boost::archive::detail::interface_iarchive&lt;boost::archive::text_iarchive&gt;::operator&gt;&gt;&lt;A *const&gt;' requested here + ia &gt;&gt; a; + ^ +../../../boost/archive/detail/iserializer.hpp:538:45: note: variable 't' declared const here + static void invoke(Archive &amp; ar, Tptr &amp; t){ + ~~~~~~~^ +2 errors generated. +(failed-as-expected) ../../../bin.v2/libs/serialization/test/test_const_load_fail2.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_const_load_fail2.o +</pre> +<h2><a name="bin.v2/libs/serialization/test/test_const_load_fail1_nvp.test/clang-darwin-03/debug/threading-multi/visibility-hidden">bin.v2/libs/serialization/test/test_const_load_fail1_nvp.test/clang-darwin-03/debug/threading-multi/visibility-hidden</a></h2> +<h3>Compiler output:</h3><pre> +In file included from test_const_load_fail1_nvp.cpp:11: +In file included from ../../../boost/archive/text_iarchive.hpp:24: +In file included from ../../../boost/archive/basic_text_iarchive.hpp:30: +In file included from ../../../boost/archive/detail/common_iarchive.hpp:23: +In file included from ../../../boost/archive/detail/interface_iarchive.hpp:22: +In file included from ../../../boost/archive/detail/iserializer.hpp:90: +../../../boost/archive/detail/check.hpp:162:5: error: implicit instantiation of undefined template 'boost::STATIC_ASSERTION_FAILURE&lt;false&gt;' + BOOST_STATIC_ASSERT(typex::value); + ^ +../../../boost/static_assert.hpp:154:13: note: expanded from macro 'BOOST_STATIC_ASSERT' + sizeof(::boost::STATIC_ASSERTION_FAILURE&lt; BOOST_STATIC_ASSERT_BOOL_CAST( __VA_ARGS__ ) &gt;)&gt;\ + ^ +../../../boost/archive/detail/iserializer.hpp:609:13: note: in instantiation of function template specialization 'boost::archive::detail::check_const_loading&lt;const A&gt;' requested here + detail::check_const_loading&lt; T &gt;(); + ^ +../../../boost/archive/detail/common_iarchive.hpp:67:18: note: in instantiation of function template specialization 'boost::archive::load&lt;boost::archive::text_iarchive, const A&gt;' requested here + archive::load(* this-&gt;This(), t); + ^ +../../../boost/archive/basic_text_iarchive.hpp:70:39: note: in instantiation of function template specialization 'boost::archive::detail::common_iarchive&lt;boost::archive::text_iarchive&gt;::load_override&lt;const A&gt;' requested here + this-&gt;detail_common_iarchive::load_override(t); + ^ +../../../boost/archive/text_iarchive.hpp:82:39: note: in instantiation of function template specialization 'boost::archive::basic_text_iarchive&lt;boost::archive::text_iarchive&gt;::load_override&lt;const A&gt;' requested here + basic_text_iarchive&lt;Archive&gt;::load_override(t); + ^ +../../../boost/archive/detail/interface_iarchive.hpp:68:23: note: in instantiation of function template specialization 'boost::archive::text_iarchive_impl&lt;boost::archive::text_iarchive&gt;::load_override&lt;const A&gt;' requested here + this-&gt;This()-&gt;load_override(t); + ^ +../../../boost/serialization/nvp.hpp:56:8: note: (skipping 8 contexts in backtrace; use -ftemplate-backtrace-limit=0 to see all) + ar &gt;&gt; t.value(); + ^ +../../../boost/archive/detail/common_iarchive.hpp:67:18: note: in instantiation of function template specialization 'boost::archive::load&lt;boost::archive::text_iarchive, const boost::serialization::nvp&lt;const A&gt; &gt;' requested here + archive::load(* this-&gt;This(), t); + ^ +../../../boost/archive/basic_text_iarchive.hpp:70:39: note: in instantiation of function template specialization 'boost::archive::detail::common_iarchive&lt;boost::archive::text_iarchive&gt;::load_override&lt;const boost::serialization::nvp&lt;const A&gt; &gt;' requested here + this-&gt;detail_common_iarchive::load_override(t); + ^ +../../../boost/archive/text_iarchive.hpp:82:39: note: in instantiation of function template specialization 'boost::archive::basic_text_iarchive&lt;boost::archive::text_iarchive&gt;::load_override&lt;const boost::serialization::nvp&lt;const A&gt; &gt;' requested here + basic_text_iarchive&lt;Archive&gt;::load_override(t); + ^ +../../../boost/archive/detail/interface_iarchive.hpp:68:23: note: in instantiation of function template specialization 'boost::archive::text_iarchive_impl&lt;boost::archive::text_iarchive&gt;::load_override&lt;const boost::serialization::nvp&lt;const A&gt; &gt;' requested here + this-&gt;This()-&gt;load_override(t); + ^ +test_const_load_fail1_nvp.cpp:23:8: note: in instantiation of function template specialization 'boost::archive::detail::interface_iarchive&lt;boost::archive::text_iarchive&gt;::operator&gt;&gt;&lt;const boost::serialization::nvp&lt;const A&gt; &gt;' requested here + ia &gt;&gt; BOOST_SERIALIZATION_NVP(a); + ^ +../../../boost/static_assert.hpp:79:26: note: template is declared here +template &lt;bool x&gt; struct STATIC_ASSERTION_FAILURE; + ^ +1 error generated. +(failed-as-expected) ../../../bin.v2/libs/serialization/test/test_const_load_fail1_nvp.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_const_load_fail1_nvp.o +</pre> +<h2><a name="bin.v2/libs/serialization/test/test_const_load_fail3.test/clang-darwin-03/debug/threading-multi/visibility-hidden">bin.v2/libs/serialization/test/test_const_load_fail3.test/clang-darwin-03/debug/threading-multi/visibility-hidden</a></h2> +<h3>Compiler output:</h3><pre> +In file included from test_const_load_fail3.cpp:11: +In file included from ../../../boost/archive/text_iarchive.hpp:24: +In file included from ../../../boost/archive/basic_text_iarchive.hpp:30: +In file included from ../../../boost/archive/detail/common_iarchive.hpp:23: +In file included from ../../../boost/archive/detail/interface_iarchive.hpp:22: +In file included from ../../../boost/archive/detail/iserializer.hpp:90: +../../../boost/archive/detail/check.hpp:162:5: error: implicit instantiation of undefined template 'boost::STATIC_ASSERTION_FAILURE&lt;false&gt;' + BOOST_STATIC_ASSERT(typex::value); + ^ +../../../boost/static_assert.hpp:154:13: note: expanded from macro 'BOOST_STATIC_ASSERT' + sizeof(::boost::STATIC_ASSERTION_FAILURE&lt; BOOST_STATIC_ASSERT_BOOL_CAST( __VA_ARGS__ ) &gt;)&gt;\ + ^ +../../../boost/archive/detail/iserializer.hpp:609:13: note: in instantiation of function template specialization 'boost::archive::detail::check_const_loading&lt;const A *const&gt;' requested here + detail::check_const_loading&lt; T &gt;(); + ^ +../../../boost/archive/detail/common_iarchive.hpp:67:18: note: in instantiation of function template specialization 'boost::archive::load&lt;boost::archive::text_iarchive, const A *const&gt;' requested here + archive::load(* this-&gt;This(), t); + ^ +../../../boost/archive/basic_text_iarchive.hpp:70:39: note: in instantiation of function template specialization 'boost::archive::detail::common_iarchive&lt;boost::archive::text_iarchive&gt;::load_override&lt;const A *const&gt;' requested here + this-&gt;detail_common_iarchive::load_override(t); + ^ +../../../boost/archive/text_iarchive.hpp:82:39: note: in instantiation of function template specialization 'boost::archive::basic_text_iarchive&lt;boost::archive::text_iarchive&gt;::load_override&lt;const A *const&gt;' requested here + basic_text_iarchive&lt;Archive&gt;::load_override(t); + ^ +../../../boost/archive/detail/interface_iarchive.hpp:68:23: note: in instantiation of function template specialization 'boost::archive::text_iarchive_impl&lt;boost::archive::text_iarchive&gt;::load_override&lt;const A *const&gt;' requested here + this-&gt;This()-&gt;load_override(t); + ^ +test_const_load_fail3.cpp:21:8: note: in instantiation of function template specialization 'boost::archive::detail::interface_iarchive&lt;boost::archive::text_iarchive&gt;::operator&gt;&gt;&lt;const A *const&gt;' requested here + ia &gt;&gt; a; + ^ +../../../boost/static_assert.hpp:79:26: note: template is declared here +template &lt;bool x&gt; struct STATIC_ASSERTION_FAILURE; + ^ +In file included from test_const_load_fail3.cpp:11: +In file included from ../../../boost/archive/text_iarchive.hpp:24: +In file included from ../../../boost/archive/basic_text_iarchive.hpp:30: +In file included from ../../../boost/archive/detail/common_iarchive.hpp:23: +In file included from ../../../boost/archive/detail/interface_iarchive.hpp:22: +../../../boost/archive/detail/iserializer.hpp:552:15: error: cannot assign to variable 't' with const-qualified type 'const A *const &amp;' + t = pointer_tweak(newbpis_ptr-&gt;get_eti(), t, *t); + ~ ^ +../../../boost/archive/detail/iserializer.hpp:624:12: note: in instantiation of function template specialization 'boost::archive::detail::load_pointer_type&lt;boost::archive::text_iarchive&gt;::invoke&lt;const A *const&gt;' requested here + typex::invoke(ar, t); + ^ +../../../boost/archive/detail/common_iarchive.hpp:67:18: note: in instantiation of function template specialization 'boost::archive::load&lt;boost::archive::text_iarchive, const A *const&gt;' requested here + archive::load(* this-&gt;This(), t); + ^ +../../../boost/archive/basic_text_iarchive.hpp:70:39: note: in instantiation of function template specialization 'boost::archive::detail::common_iarchive&lt;boost::archive::text_iarchive&gt;::load_override&lt;const A *const&gt;' requested here + this-&gt;detail_common_iarchive::load_override(t); + ^ +../../../boost/archive/text_iarchive.hpp:82:39: note: in instantiation of function template specialization 'boost::archive::basic_text_iarchive&lt;boost::archive::text_iarchive&gt;::load_override&lt;const A *const&gt;' requested here + basic_text_iarchive&lt;Archive&gt;::load_override(t); + ^ +../../../boost/archive/detail/interface_iarchive.hpp:68:23: note: in instantiation of function template specialization 'boost::archive::text_iarchive_impl&lt;boost::archive::text_iarchive&gt;::load_override&lt;const A *const&gt;' requested here + this-&gt;This()-&gt;load_override(t); + ^ +test_const_load_fail3.cpp:21:8: note: in instantiation of function template specialization 'boost::archive::detail::interface_iarchive&lt;boost::archive::text_iarchive&gt;::operator&gt;&gt;&lt;const A *const&gt;' requested here + ia &gt;&gt; a; + ^ +../../../boost/archive/detail/iserializer.hpp:538:45: note: variable 't' declared const here + static void invoke(Archive &amp; ar, Tptr &amp; t){ + ~~~~~~~^ +2 errors generated. +(failed-as-expected) ../../../bin.v2/libs/serialization/test/test_const_load_fail3.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_const_load_fail3.o +</pre> +<h2><a name="bin.v2/libs/serialization/test/test_dll_exported_polymorphic_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden">bin.v2/libs/serialization/test/test_dll_exported_polymorphic_text_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden</a></h2> +<h3>Compiler output:</h3><pre> +In file included from test_dll_exported.cpp:51: +./polymorphic_base.hpp:29:13: warning: polymorphic_base imported [-W#pragma-messages] + #pragma message ("polymorphic_base imported") + ^ +In file included from test_dll_exported.cpp:56: +./polymorphic_derived2.hpp:29:13: warning: polymorphic_derived2 imported [-W#pragma-messages] + #pragma message ("polymorphic_derived2 imported") + ^ +2 warnings generated. +</pre> +<h2><a name="bin.v2/libs/serialization/test/test_singleton_plain.test/clang-darwin-03/debug/threading-multi/visibility-hidden">bin.v2/libs/serialization/test/test_singleton_plain.test/clang-darwin-03/debug/threading-multi/visibility-hidden</a></h2> +<h3>Compiler output:</h3><pre> +test_singleton_plain.cpp:25:32: warning: unknown warning group '-Wterminate', ignored [-Wunknown-warning-option] +#pragma GCC diagnostic ignored "-Wterminate" + ^ +1 warning generated. +</pre> +<h2><a name="bin.v2/libs/serialization/test/test_singleton_inherited.test/clang-darwin-03/debug/threading-multi/visibility-hidden">bin.v2/libs/serialization/test/test_singleton_inherited.test/clang-darwin-03/debug/threading-multi/visibility-hidden</a></h2> +<h3>Compiler output:</h3><pre> +test_singleton_inherited.cpp:26:32: warning: unknown warning group '-Wterminate', ignored [-Wunknown-warning-option] +#pragma GCC diagnostic ignored "-Wterminate" + ^ +1 warning generated. +</pre> +<h2><a name="bin.v2/libs/serialization/test/test_dll_simple.test/clang-darwin-03/debug/threading-multi/visibility-hidden">bin.v2/libs/serialization/test/test_dll_simple.test/clang-darwin-03/debug/threading-multi/visibility-hidden</a></h2> +<h3>Compiler output:</h3><pre> +In file included from test_dll_simple.cpp:33: +./A.hpp:37:13: warning: A imported [-W#pragma-messages] + #pragma message("A imported") + ^ +1 warning generated. +</pre> +<h2><a name="bin.v2/libs/serialization/test/test_dll_exported_polymorphic_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden">bin.v2/libs/serialization/test/test_dll_exported_polymorphic_binary_archive.test/clang-darwin-03/debug/threading-multi/visibility-hidden</a></h2> +<h3>Compiler output:</h3><pre> +In file included from test_dll_exported.cpp:51: +./polymorphic_base.hpp:29:13: warning: polymorphic_base imported [-W#pragma-messages] + #pragma message ("polymorphic_base imported") + ^ +In file included from test_dll_exported.cpp:56: +./polymorphic_derived2.hpp:29:13: warning: polymorphic_derived2 imported [-W#pragma-messages] + #pragma message ("polymorphic_derived2 imported") + ^ +2 warnings generated. +</pre> +<h2><a name="bin.v2/libs/serialization/test/test_traits_fail.test/clang-darwin-03/debug/threading-multi/visibility-hidden">bin.v2/libs/serialization/test/test_traits_fail.test/clang-darwin-03/debug/threading-multi/visibility-hidden</a></h2> +<h3>Compiler output:</h3><pre> +test_traits_fail.cpp:24:1: error: implicit instantiation of undefined template 'boost::STATIC_ASSERTION_FAILURE&lt;false&gt;' +BOOST_CLASS_TRACKING(A, boost::serialization::track_never) +^ +../../../boost/serialization/tracking.hpp:108:5: note: expanded from macro 'BOOST_CLASS_TRACKING' + BOOST_STATIC_ASSERT(( \ + ^ +../../../boost/static_assert.hpp:154:13: note: expanded from macro 'BOOST_STATIC_ASSERT' + sizeof(::boost::STATIC_ASSERTION_FAILURE&lt; BOOST_STATIC_ASSERT_BOOL_CAST( __VA_ARGS__ ) &gt;)&gt;\ + ^ +../../../boost/static_assert.hpp:79:26: note: template is declared here +template &lt;bool x&gt; struct STATIC_ASSERTION_FAILURE; + ^ +1 error generated. +(failed-as-expected) ../../../bin.v2/libs/serialization/test/test_traits_fail.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_traits_fail.o +</pre> +<h2><a name="bin.v2/libs/serialization/test/test_const_load_fail1.test/clang-darwin-03/debug/threading-multi/visibility-hidden">bin.v2/libs/serialization/test/test_const_load_fail1.test/clang-darwin-03/debug/threading-multi/visibility-hidden</a></h2> +<h3>Compiler output:</h3><pre> +In file included from test_const_load_fail1.cpp:11: +In file included from ../../../boost/archive/text_iarchive.hpp:24: +In file included from ../../../boost/archive/basic_text_iarchive.hpp:30: +In file included from ../../../boost/archive/detail/common_iarchive.hpp:23: +In file included from ../../../boost/archive/detail/interface_iarchive.hpp:22: +In file included from ../../../boost/archive/detail/iserializer.hpp:90: +../../../boost/archive/detail/check.hpp:162:5: error: implicit instantiation of undefined template 'boost::STATIC_ASSERTION_FAILURE&lt;false&gt;' + BOOST_STATIC_ASSERT(typex::value); + ^ +../../../boost/static_assert.hpp:154:13: note: expanded from macro 'BOOST_STATIC_ASSERT' + sizeof(::boost::STATIC_ASSERTION_FAILURE&lt; BOOST_STATIC_ASSERT_BOOL_CAST( __VA_ARGS__ ) &gt;)&gt;\ + ^ +../../../boost/archive/detail/iserializer.hpp:609:13: note: in instantiation of function template specialization 'boost::archive::detail::check_const_loading&lt;const A&gt;' requested here + detail::check_const_loading&lt; T &gt;(); + ^ +../../../boost/archive/detail/common_iarchive.hpp:67:18: note: in instantiation of function template specialization 'boost::archive::load&lt;boost::archive::text_iarchive, const A&gt;' requested here + archive::load(* this-&gt;This(), t); + ^ +../../../boost/archive/basic_text_iarchive.hpp:70:39: note: in instantiation of function template specialization 'boost::archive::detail::common_iarchive&lt;boost::archive::text_iarchive&gt;::load_override&lt;const A&gt;' requested here + this-&gt;detail_common_iarchive::load_override(t); + ^ +../../../boost/archive/text_iarchive.hpp:82:39: note: in instantiation of function template specialization 'boost::archive::basic_text_iarchive&lt;boost::archive::text_iarchive&gt;::load_override&lt;const A&gt;' requested here + basic_text_iarchive&lt;Archive&gt;::load_override(t); + ^ +../../../boost/archive/detail/interface_iarchive.hpp:68:23: note: in instantiation of function template specialization 'boost::archive::text_iarchive_impl&lt;boost::archive::text_iarchive&gt;::load_override&lt;const A&gt;' requested here + this-&gt;This()-&gt;load_override(t); + ^ +test_const_load_fail1.cpp:22:8: note: in instantiation of function template specialization 'boost::archive::detail::interface_iarchive&lt;boost::archive::text_iarchive&gt;::operator&gt;&gt;&lt;const A&gt;' requested here + ia &gt;&gt; a; + ^ +../../../boost/static_assert.hpp:79:26: note: template is declared here +template &lt;bool x&gt; struct STATIC_ASSERTION_FAILURE; + ^ +1 error generated. +(failed-as-expected) ../../../bin.v2/libs/serialization/test/test_const_load_fail1.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_const_load_fail1.o +</pre> +<h2><a name="bin.v2/libs/serialization/test/test_smart_cast.test/clang-darwin-03/debug/threading-multi/visibility-hidden">bin.v2/libs/serialization/test/test_smart_cast.test/clang-darwin-03/debug/threading-multi/visibility-hidden</a></h2> +<h3>Compiler output:</h3><pre> +test_smart_cast.cpp:20:10: warning: private field 'a' is not used [-Wunused-private-field] + char a; + ^ +test_smart_cast.cpp:25:9: warning: private field 'b' is not used [-Wunused-private-field] + int b; + ^ +test_smart_cast.cpp:35:10: warning: private field 'c' is not used [-Wunused-private-field] + long c; + ^ +test_smart_cast.cpp:122:10: warning: private field 'a' is not used [-Wunused-private-field] + char a; + ^ +test_smart_cast.cpp:129:9: warning: private field 'b' is not used [-Wunused-private-field] + int b; + ^ +test_smart_cast.cpp:141:10: warning: private field 'c' is not used [-Wunused-private-field] + long c; + ^ +6 warnings generated. +</pre> +<h2><a name="bin.v2/libs/serialization/test/test_const_load_fail2_nvp.test/clang-darwin-03/debug/threading-multi/visibility-hidden">bin.v2/libs/serialization/test/test_const_load_fail2_nvp.test/clang-darwin-03/debug/threading-multi/visibility-hidden</a></h2> +<h3>Compiler output:</h3><pre> +In file included from test_const_load_fail2_nvp.cpp:11: +In file included from ../../../boost/archive/text_iarchive.hpp:24: +In file included from ../../../boost/archive/basic_text_iarchive.hpp:30: +In file included from ../../../boost/archive/detail/common_iarchive.hpp:23: +In file included from ../../../boost/archive/detail/interface_iarchive.hpp:22: +In file included from ../../../boost/archive/detail/iserializer.hpp:90: +../../../boost/archive/detail/check.hpp:162:5: error: implicit instantiation of undefined template 'boost::STATIC_ASSERTION_FAILURE&lt;false&gt;' + BOOST_STATIC_ASSERT(typex::value); + ^ +../../../boost/static_assert.hpp:154:13: note: expanded from macro 'BOOST_STATIC_ASSERT' + sizeof(::boost::STATIC_ASSERTION_FAILURE&lt; BOOST_STATIC_ASSERT_BOOL_CAST( __VA_ARGS__ ) &gt;)&gt;\ + ^ +../../../boost/archive/detail/iserializer.hpp:609:13: note: in instantiation of function template specialization 'boost::archive::detail::check_const_loading&lt;A *const&gt;' requested here + detail::check_const_loading&lt; T &gt;(); + ^ +../../../boost/archive/detail/common_iarchive.hpp:67:18: note: in instantiation of function template specialization 'boost::archive::load&lt;boost::archive::text_iarchive, A *const&gt;' requested here + archive::load(* this-&gt;This(), t); + ^ +../../../boost/archive/basic_text_iarchive.hpp:70:39: note: in instantiation of function template specialization 'boost::archive::detail::common_iarchive&lt;boost::archive::text_iarchive&gt;::load_override&lt;A *const&gt;' requested here + this-&gt;detail_common_iarchive::load_override(t); + ^ +../../../boost/archive/text_iarchive.hpp:82:39: note: in instantiation of function template specialization 'boost::archive::basic_text_iarchive&lt;boost::archive::text_iarchive&gt;::load_override&lt;A *const&gt;' requested here + basic_text_iarchive&lt;Archive&gt;::load_override(t); + ^ +../../../boost/archive/detail/interface_iarchive.hpp:68:23: note: in instantiation of function template specialization 'boost::archive::text_iarchive_impl&lt;boost::archive::text_iarchive&gt;::load_override&lt;A *const&gt;' requested here + this-&gt;This()-&gt;load_override(t); + ^ +../../../boost/serialization/nvp.hpp:56:8: note: (skipping 8 contexts in backtrace; use -ftemplate-backtrace-limit=0 to see all) + ar &gt;&gt; t.value(); + ^ +../../../boost/archive/detail/common_iarchive.hpp:67:18: note: in instantiation of function template specialization 'boost::archive::load&lt;boost::archive::text_iarchive, const boost::serialization::nvp&lt;A *const&gt; &gt;' requested here + archive::load(* this-&gt;This(), t); + ^ +../../../boost/archive/basic_text_iarchive.hpp:70:39: note: in instantiation of function template specialization 'boost::archive::detail::common_iarchive&lt;boost::archive::text_iarchive&gt;::load_override&lt;const boost::serialization::nvp&lt;A *const&gt; &gt;' requested here + this-&gt;detail_common_iarchive::load_override(t); + ^ +../../../boost/archive/text_iarchive.hpp:82:39: note: in instantiation of function template specialization 'boost::archive::basic_text_iarchive&lt;boost::archive::text_iarchive&gt;::load_override&lt;const boost::serialization::nvp&lt;A *const&gt; &gt;' requested here + basic_text_iarchive&lt;Archive&gt;::load_override(t); + ^ +../../../boost/archive/detail/interface_iarchive.hpp:68:23: note: in instantiation of function template specialization 'boost::archive::text_iarchive_impl&lt;boost::archive::text_iarchive&gt;::load_override&lt;const boost::serialization::nvp&lt;A *const&gt; &gt;' requested here + this-&gt;This()-&gt;load_override(t); + ^ +test_const_load_fail2_nvp.cpp:23:8: note: in instantiation of function template specialization 'boost::archive::detail::interface_iarchive&lt;boost::archive::text_iarchive&gt;::operator&gt;&gt;&lt;const boost::serialization::nvp&lt;A *const&gt; &gt;' requested here + ia &gt;&gt; BOOST_SERIALIZATION_NVP(a); + ^ +../../../boost/static_assert.hpp:79:26: note: template is declared here +template &lt;bool x&gt; struct STATIC_ASSERTION_FAILURE; + ^ +In file included from test_const_load_fail2_nvp.cpp:11: +In file included from ../../../boost/archive/text_iarchive.hpp:24: +In file included from ../../../boost/archive/basic_text_iarchive.hpp:30: +In file included from ../../../boost/archive/detail/common_iarchive.hpp:23: +In file included from ../../../boost/archive/detail/interface_iarchive.hpp:22: +../../../boost/archive/detail/iserializer.hpp:552:15: error: cannot assign to variable 't' with const-qualified type 'A *const &amp;' + t = pointer_tweak(newbpis_ptr-&gt;get_eti(), t, *t); + ~ ^ +../../../boost/archive/detail/iserializer.hpp:624:12: note: in instantiation of function template specialization 'boost::archive::detail::load_pointer_type&lt;boost::archive::text_iarchive&gt;::invoke&lt;A *const&gt;' requested here + typex::invoke(ar, t); + ^ +../../../boost/archive/detail/common_iarchive.hpp:67:18: note: in instantiation of function template specialization 'boost::archive::load&lt;boost::archive::text_iarchive, A *const&gt;' requested here + archive::load(* this-&gt;This(), t); + ^ +../../../boost/archive/basic_text_iarchive.hpp:70:39: note: in instantiation of function template specialization 'boost::archive::detail::common_iarchive&lt;boost::archive::text_iarchive&gt;::load_override&lt;A *const&gt;' requested here + this-&gt;detail_common_iarchive::load_override(t); + ^ +../../../boost/archive/text_iarchive.hpp:82:39: note: in instantiation of function template specialization 'boost::archive::basic_text_iarchive&lt;boost::archive::text_iarchive&gt;::load_override&lt;A *const&gt;' requested here + basic_text_iarchive&lt;Archive&gt;::load_override(t); + ^ +../../../boost/archive/detail/interface_iarchive.hpp:68:23: note: in instantiation of function template specialization 'boost::archive::text_iarchive_impl&lt;boost::archive::text_iarchive&gt;::load_override&lt;A *const&gt;' requested here + this-&gt;This()-&gt;load_override(t); + ^ +../../../boost/serialization/nvp.hpp:56:8: note: (skipping 8 contexts in backtrace; use -ftemplate-backtrace-limit=0 to see all) + ar &gt;&gt; t.value(); + ^ +../../../boost/archive/detail/common_iarchive.hpp:67:18: note: in instantiation of function template specialization 'boost::archive::load&lt;boost::archive::text_iarchive, const boost::serialization::nvp&lt;A *const&gt; &gt;' requested here + archive::load(* this-&gt;This(), t); + ^ +../../../boost/archive/basic_text_iarchive.hpp:70:39: note: in instantiation of function template specialization 'boost::archive::detail::common_iarchive&lt;boost::archive::text_iarchive&gt;::load_override&lt;const boost::serialization::nvp&lt;A *const&gt; &gt;' requested here + this-&gt;detail_common_iarchive::load_override(t); + ^ +../../../boost/archive/text_iarchive.hpp:82:39: note: in instantiation of function template specialization 'boost::archive::basic_text_iarchive&lt;boost::archive::text_iarchive&gt;::load_override&lt;const boost::serialization::nvp&lt;A *const&gt; &gt;' requested here + basic_text_iarchive&lt;Archive&gt;::load_override(t); + ^ +../../../boost/archive/detail/interface_iarchive.hpp:68:23: note: in instantiation of function template specialization 'boost::archive::text_iarchive_impl&lt;boost::archive::text_iarchive&gt;::load_override&lt;const boost::serialization::nvp&lt;A *const&gt; &gt;' requested here + this-&gt;This()-&gt;load_override(t); + ^ +test_const_load_fail2_nvp.cpp:23:8: note: in instantiation of function template specialization 'boost::archive::detail::interface_iarchive&lt;boost::archive::text_iarchive&gt;::operator&gt;&gt;&lt;const boost::serialization::nvp&lt;A *const&gt; &gt;' requested here + ia &gt;&gt; BOOST_SERIALIZATION_NVP(a); + ^ +../../../boost/archive/detail/iserializer.hpp:538:45: note: variable 't' declared const here + static void invoke(Archive &amp; ar, Tptr &amp; t){ + ~~~~~~~^ +2 errors generated. +(failed-as-expected) ../../../bin.v2/libs/serialization/test/test_const_load_fail2_nvp.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_const_load_fail2_nvp.o +</pre> +<h2><a name="bin.v2/libs/serialization/test/test_const_load_fail3_nvp.test/clang-darwin-03/debug/threading-multi/visibility-hidden">bin.v2/libs/serialization/test/test_const_load_fail3_nvp.test/clang-darwin-03/debug/threading-multi/visibility-hidden</a></h2> +<h3>Compiler output:</h3><pre> +In file included from test_const_load_fail3_nvp.cpp:11: +In file included from ../../../boost/archive/text_iarchive.hpp:24: +In file included from ../../../boost/archive/basic_text_iarchive.hpp:30: +In file included from ../../../boost/archive/detail/common_iarchive.hpp:23: +In file included from ../../../boost/archive/detail/interface_iarchive.hpp:22: +In file included from ../../../boost/archive/detail/iserializer.hpp:90: +../../../boost/archive/detail/check.hpp:162:5: error: implicit instantiation of undefined template 'boost::STATIC_ASSERTION_FAILURE&lt;false&gt;' + BOOST_STATIC_ASSERT(typex::value); + ^ +../../../boost/static_assert.hpp:154:13: note: expanded from macro 'BOOST_STATIC_ASSERT' + sizeof(::boost::STATIC_ASSERTION_FAILURE&lt; BOOST_STATIC_ASSERT_BOOL_CAST( __VA_ARGS__ ) &gt;)&gt;\ + ^ +../../../boost/archive/detail/iserializer.hpp:609:13: note: in instantiation of function template specialization 'boost::archive::detail::check_const_loading&lt;const A *const&gt;' requested here + detail::check_const_loading&lt; T &gt;(); + ^ +../../../boost/archive/detail/common_iarchive.hpp:67:18: note: in instantiation of function template specialization 'boost::archive::load&lt;boost::archive::text_iarchive, const A *const&gt;' requested here + archive::load(* this-&gt;This(), t); + ^ +../../../boost/archive/basic_text_iarchive.hpp:70:39: note: in instantiation of function template specialization 'boost::archive::detail::common_iarchive&lt;boost::archive::text_iarchive&gt;::load_override&lt;const A *const&gt;' requested here + this-&gt;detail_common_iarchive::load_override(t); + ^ +../../../boost/archive/text_iarchive.hpp:82:39: note: in instantiation of function template specialization 'boost::archive::basic_text_iarchive&lt;boost::archive::text_iarchive&gt;::load_override&lt;const A *const&gt;' requested here + basic_text_iarchive&lt;Archive&gt;::load_override(t); + ^ +../../../boost/archive/detail/interface_iarchive.hpp:68:23: note: in instantiation of function template specialization 'boost::archive::text_iarchive_impl&lt;boost::archive::text_iarchive&gt;::load_override&lt;const A *const&gt;' requested here + this-&gt;This()-&gt;load_override(t); + ^ +../../../boost/serialization/nvp.hpp:56:8: note: (skipping 8 contexts in backtrace; use -ftemplate-backtrace-limit=0 to see all) + ar &gt;&gt; t.value(); + ^ +../../../boost/archive/detail/common_iarchive.hpp:67:18: note: in instantiation of function template specialization 'boost::archive::load&lt;boost::archive::text_iarchive, const boost::serialization::nvp&lt;const A *const&gt; &gt;' requested here + archive::load(* this-&gt;This(), t); + ^ +../../../boost/archive/basic_text_iarchive.hpp:70:39: note: in instantiation of function template specialization 'boost::archive::detail::common_iarchive&lt;boost::archive::text_iarchive&gt;::load_override&lt;const boost::serialization::nvp&lt;const A *const&gt; &gt;' requested here + this-&gt;detail_common_iarchive::load_override(t); + ^ +../../../boost/archive/text_iarchive.hpp:82:39: note: in instantiation of function template specialization 'boost::archive::basic_text_iarchive&lt;boost::archive::text_iarchive&gt;::load_override&lt;const boost::serialization::nvp&lt;const A *const&gt; &gt;' requested here + basic_text_iarchive&lt;Archive&gt;::load_override(t); + ^ +../../../boost/archive/detail/interface_iarchive.hpp:68:23: note: in instantiation of function template specialization 'boost::archive::text_iarchive_impl&lt;boost::archive::text_iarchive&gt;::load_override&lt;const boost::serialization::nvp&lt;const A *const&gt; &gt;' requested here + this-&gt;This()-&gt;load_override(t); + ^ +test_const_load_fail3_nvp.cpp:23:8: note: in instantiation of function template specialization 'boost::archive::detail::interface_iarchive&lt;boost::archive::text_iarchive&gt;::operator&gt;&gt;&lt;const boost::serialization::nvp&lt;const A *const&gt; &gt;' requested here + ia &gt;&gt; BOOST_SERIALIZATION_NVP(a); + ^ +../../../boost/static_assert.hpp:79:26: note: template is declared here +template &lt;bool x&gt; struct STATIC_ASSERTION_FAILURE; + ^ +In file included from test_const_load_fail3_nvp.cpp:11: +In file included from ../../../boost/archive/text_iarchive.hpp:24: +In file included from ../../../boost/archive/basic_text_iarchive.hpp:30: +In file included from ../../../boost/archive/detail/common_iarchive.hpp:23: +In file included from ../../../boost/archive/detail/interface_iarchive.hpp:22: +../../../boost/archive/detail/iserializer.hpp:552:15: error: cannot assign to variable 't' with const-qualified type 'const A *const &amp;' + t = pointer_tweak(newbpis_ptr-&gt;get_eti(), t, *t); + ~ ^ +../../../boost/archive/detail/iserializer.hpp:624:12: note: in instantiation of function template specialization 'boost::archive::detail::load_pointer_type&lt;boost::archive::text_iarchive&gt;::invoke&lt;const A *const&gt;' requested here + typex::invoke(ar, t); + ^ +../../../boost/archive/detail/common_iarchive.hpp:67:18: note: in instantiation of function template specialization 'boost::archive::load&lt;boost::archive::text_iarchive, const A *const&gt;' requested here + archive::load(* this-&gt;This(), t); + ^ +../../../boost/archive/basic_text_iarchive.hpp:70:39: note: in instantiation of function template specialization 'boost::archive::detail::common_iarchive&lt;boost::archive::text_iarchive&gt;::load_override&lt;const A *const&gt;' requested here + this-&gt;detail_common_iarchive::load_override(t); + ^ +../../../boost/archive/text_iarchive.hpp:82:39: note: in instantiation of function template specialization 'boost::archive::basic_text_iarchive&lt;boost::archive::text_iarchive&gt;::load_override&lt;const A *const&gt;' requested here + basic_text_iarchive&lt;Archive&gt;::load_override(t); + ^ +../../../boost/archive/detail/interface_iarchive.hpp:68:23: note: in instantiation of function template specialization 'boost::archive::text_iarchive_impl&lt;boost::archive::text_iarchive&gt;::load_override&lt;const A *const&gt;' requested here + this-&gt;This()-&gt;load_override(t); + ^ +../../../boost/serialization/nvp.hpp:56:8: note: (skipping 8 contexts in backtrace; use -ftemplate-backtrace-limit=0 to see all) + ar &gt;&gt; t.value(); + ^ +../../../boost/archive/detail/common_iarchive.hpp:67:18: note: in instantiation of function template specialization 'boost::archive::load&lt;boost::archive::text_iarchive, const boost::serialization::nvp&lt;const A *const&gt; &gt;' requested here + archive::load(* this-&gt;This(), t); + ^ +../../../boost/archive/basic_text_iarchive.hpp:70:39: note: in instantiation of function template specialization 'boost::archive::detail::common_iarchive&lt;boost::archive::text_iarchive&gt;::load_override&lt;const boost::serialization::nvp&lt;const A *const&gt; &gt;' requested here + this-&gt;detail_common_iarchive::load_override(t); + ^ +../../../boost/archive/text_iarchive.hpp:82:39: note: in instantiation of function template specialization 'boost::archive::basic_text_iarchive&lt;boost::archive::text_iarchive&gt;::load_override&lt;const boost::serialization::nvp&lt;const A *const&gt; &gt;' requested here + basic_text_iarchive&lt;Archive&gt;::load_override(t); + ^ +../../../boost/archive/detail/interface_iarchive.hpp:68:23: note: in instantiation of function template specialization 'boost::archive::text_iarchive_impl&lt;boost::archive::text_iarchive&gt;::load_override&lt;const boost::serialization::nvp&lt;const A *const&gt; &gt;' requested here + this-&gt;This()-&gt;load_override(t); + ^ +test_const_load_fail3_nvp.cpp:23:8: note: in instantiation of function template specialization 'boost::archive::detail::interface_iarchive&lt;boost::archive::text_iarchive&gt;::operator&gt;&gt;&lt;const boost::serialization::nvp&lt;const A *const&gt; &gt;' requested here + ia &gt;&gt; BOOST_SERIALIZATION_NVP(a); + ^ +../../../boost/archive/detail/iserializer.hpp:538:45: note: variable 't' declared const here + static void invoke(Archive &amp; ar, Tptr &amp; t){ + ~~~~~~~^ +2 errors generated. +(failed-as-expected) ../../../bin.v2/libs/serialization/test/test_const_load_fail3_nvp.test/clang-darwin-03/debug/threading-multi/visibility-hidden/test_const_load_fail3_nvp.o +</pre> +<h2><a name="bin.v2/libs/serialization/test/test_dll_exported_polymorphic_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden">bin.v2/libs/serialization/test/test_dll_exported_polymorphic_text_warchive.test/clang-darwin-03/debug/threading-multi/visibility-hidden</a></h2> +<h3>Compiler output:</h3><pre> +In file included from test_dll_exported.cpp:51: +./polymorphic_base.hpp:29:13: warning: polymorphic_base imported [-W#pragma-messages] + #pragma message ("polymorphic_base imported") + ^ +In file included from test_dll_exported.cpp:56: +./polymorphic_derived2.hpp:29:13: warning: polymorphic_derived2 imported [-W#pragma-messages] + #pragma message ("polymorphic_derived2 imported") + ^ +2 warnings generated. +</pre> +<h2><a name="bin.v2/libs/serialization/test/test_void_cast.test/clang-darwin-03/debug/threading-multi/visibility-hidden">bin.v2/libs/serialization/test/test_void_cast.test/clang-darwin-03/debug/threading-multi/visibility-hidden</a></h2> +<h3>Compiler output:</h3><pre> +test_void_cast.cpp:18:10: warning: private field 'a' is not used [-Wunused-private-field] + char a; + ^ +test_void_cast.cpp:23:9: warning: private field 'b' is not used [-Wunused-private-field] + int b; + ^ +test_void_cast.cpp:28:10: warning: private field 'c' is not used [-Wunused-private-field] + long c; + ^ +test_void_cast.cpp:33:10: warning: private field 'd' is not used [-Wunused-private-field] + char d[32]; + ^ +4 warnings generated. +</pre> +</body> +</html> diff --git a/src/boost/libs/serialization/test/multi_shared1.cpp b/src/boost/libs/serialization/test/multi_shared1.cpp new file mode 100644 index 00000000..ddb6174e --- /dev/null +++ b/src/boost/libs/serialization/test/multi_shared1.cpp @@ -0,0 +1,23 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_multi_shared_lib.cpp: test that implementation of extented_type_info +// works when using multiple shared libraries + +// (C) Copyright 2018 Alexander Grund +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +#include <boost/archive/text_oarchive.hpp> +#include <iostream> + +struct X1{ + template<class Archive> + void serialize(Archive &, const unsigned int){} +}; + +BOOST_CLASS_IMPLEMENTATION(X1, boost::serialization::object_class_info) + +BOOST_SYMBOL_EXPORT bool f(){ + boost::archive::text_oarchive(std::cout) & X1(); + return true; +} diff --git a/src/boost/libs/serialization/test/multi_shared2.cpp b/src/boost/libs/serialization/test/multi_shared2.cpp new file mode 100644 index 00000000..12e0a87f --- /dev/null +++ b/src/boost/libs/serialization/test/multi_shared2.cpp @@ -0,0 +1,22 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// multi_shared2.cpp: library simply using extended_type_info_typeid + +// (C) Copyright 2018 Alexander Grund +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +#include <boost/archive/text_oarchive.hpp> +#include <iostream> + +struct X2{ + template<class Archive> + void serialize(Archive &, const unsigned int){} +}; + +BOOST_CLASS_IMPLEMENTATION(X2, boost::serialization::object_class_info) + +BOOST_SYMBOL_EXPORT bool g(){ + boost::archive::text_oarchive(std::cout) & X2(); + return true; +} diff --git a/src/boost/libs/serialization/test/polymorphic_array_binary_archive.hpp b/src/boost/libs/serialization/test/polymorphic_array_binary_archive.hpp new file mode 100644 index 00000000..5097433a --- /dev/null +++ b/src/boost/libs/serialization/test/polymorphic_array_binary_archive.hpp @@ -0,0 +1,13 @@ +// (C) Copyright 2002-4 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. +#include <boost/archive/polymorphic_binary_oarchive.hpp> +typedef boost::archive::polymorphic_binary_oarchive test_oarchive; +typedef std::ofstream test_ostream; +#include <boost/archive/polymorphic_binary_iarchive.hpp> +typedef boost::archive::polymorphic_binary_iarchive test_iarchive; +typedef std::ifstream test_istream; +#define TEST_STREAM_FLAGS std::ios::binary diff --git a/src/boost/libs/serialization/test/polymorphic_base.cpp b/src/boost/libs/serialization/test/polymorphic_base.cpp new file mode 100644 index 00000000..c7bc8f4c --- /dev/null +++ b/src/boost/libs/serialization/test/polymorphic_base.cpp @@ -0,0 +1,38 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// polymorphic_base.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <boost/serialization/export.hpp> + +#include "polymorphic_base.hpp" + +template<class Archive> +POLYMORPHIC_BASE_DLL_DECL void polymorphic_base::serialize( + Archive &ar, + const unsigned int /* file_version */ +){} + +POLYMORPHIC_BASE_DLL_DECL +polymorphic_base::polymorphic_base(){} +POLYMORPHIC_BASE_DLL_DECL +polymorphic_base::~polymorphic_base(){} + +#include <boost/archive/polymorphic_oarchive.hpp> +#include <boost/archive/polymorphic_iarchive.hpp> + +template +POLYMORPHIC_BASE_DLL_DECL void polymorphic_base::serialize( + boost::archive::polymorphic_oarchive &, + const unsigned int /* file_version */ +); +template POLYMORPHIC_BASE_DLL_DECL void polymorphic_base::serialize( + boost::archive::polymorphic_iarchive &, + const unsigned int +); +BOOST_CLASS_EXPORT_IMPLEMENT(polymorphic_base) diff --git a/src/boost/libs/serialization/test/polymorphic_base.hpp b/src/boost/libs/serialization/test/polymorphic_base.hpp new file mode 100644 index 00000000..b0091f37 --- /dev/null +++ b/src/boost/libs/serialization/test/polymorphic_base.hpp @@ -0,0 +1,66 @@ +#ifndef POLYMORPHIC_BASE_HPP +#define POLYMORPHIC_BASE_HPP + +// MS compatible compilers support #pragma once +#if defined(_MSC_VER) +# pragma once +#endif + +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// polymorphic_base.hpp simple class test + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <boost/config.hpp> + +#include <boost/serialization/access.hpp> +#include <boost/serialization/assume_abstract.hpp> +#include <boost/serialization/export.hpp> +#include <boost/serialization/type_info_implementation.hpp> +#include <boost/serialization/extended_type_info_no_rtti.hpp> + +#if defined(POLYMORPHIC_BASE_IMPORT) + #define POLYMORPHIC_BASE_DLL_DECL BOOST_SYMBOL_IMPORT + #pragma message ("polymorphic_base imported") +#elif defined(POLYMORPHIC_BASE_EXPORT) + #define POLYMORPHIC_BASE_DLL_DECL BOOST_SYMBOL_EXPORT + #pragma message ("polymorphic_base exported") +#endif + +#ifndef POLYMORPHIC_BASE_DLL_DECL + #define POLYMORPHIC_BASE_DLL_DECL +#endif + +class BOOST_SYMBOL_VISIBLE polymorphic_base +{ + friend class boost::serialization::access; + template<class Archive> + POLYMORPHIC_BASE_DLL_DECL void serialize( + Archive & /* ar */, + const unsigned int /* file_version */ + ); +public: + // note that since this class uses the "no_rtti" + // extended_type_info implementation, it MUST + // implement this function + virtual const char * get_key() const = 0; + POLYMORPHIC_BASE_DLL_DECL polymorphic_base(); + POLYMORPHIC_BASE_DLL_DECL virtual ~polymorphic_base(); +}; + +BOOST_SERIALIZATION_ASSUME_ABSTRACT(polymorphic_base) + +// the no_rtti system requires this !!! +BOOST_CLASS_EXPORT_KEY(polymorphic_base) + +BOOST_CLASS_TYPE_INFO( + polymorphic_base, + extended_type_info_no_rtti<polymorphic_base> +) + +#endif // POLYMORPHIC_BASE_HPP diff --git a/src/boost/libs/serialization/test/polymorphic_binary_archive.hpp b/src/boost/libs/serialization/test/polymorphic_binary_archive.hpp new file mode 100644 index 00000000..5097433a --- /dev/null +++ b/src/boost/libs/serialization/test/polymorphic_binary_archive.hpp @@ -0,0 +1,13 @@ +// (C) Copyright 2002-4 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. +#include <boost/archive/polymorphic_binary_oarchive.hpp> +typedef boost::archive::polymorphic_binary_oarchive test_oarchive; +typedef std::ofstream test_ostream; +#include <boost/archive/polymorphic_binary_iarchive.hpp> +typedef boost::archive::polymorphic_binary_iarchive test_iarchive; +typedef std::ifstream test_istream; +#define TEST_STREAM_FLAGS std::ios::binary diff --git a/src/boost/libs/serialization/test/polymorphic_derived1.cpp b/src/boost/libs/serialization/test/polymorphic_derived1.cpp new file mode 100644 index 00000000..8e6aa857 --- /dev/null +++ b/src/boost/libs/serialization/test/polymorphic_derived1.cpp @@ -0,0 +1,37 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// polymorphic_derived1.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <boost/serialization/type_info_implementation.hpp> +#include <boost/serialization/export.hpp> + +#include "polymorphic_derived1.hpp" + +const char * polymorphic_derived1::get_key() const { + return + boost::serialization::type_info_implementation< + polymorphic_derived1 + >::type::get_const_instance().get_key(); +} + +#include <boost/archive/polymorphic_oarchive.hpp> +#include <boost/archive/polymorphic_iarchive.hpp> + +template +void polymorphic_derived1::serialize( + boost::archive::polymorphic_oarchive &, + const unsigned int /* file_version */ +); +template +void polymorphic_derived1::serialize( + boost::archive::polymorphic_iarchive &, + const unsigned int +); + +BOOST_CLASS_EXPORT_IMPLEMENT(polymorphic_derived1) diff --git a/src/boost/libs/serialization/test/polymorphic_derived1.hpp b/src/boost/libs/serialization/test/polymorphic_derived1.hpp new file mode 100644 index 00000000..0ded6703 --- /dev/null +++ b/src/boost/libs/serialization/test/polymorphic_derived1.hpp @@ -0,0 +1,45 @@ +#ifndef POLYMORPHIC_DERIVED1_HPP +#define POLYMORPHIC_DERIVED1_HPP + +// MS compatible compilers support #pragma once +#if defined(_MSC_VER) +# pragma once +#endif + +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// polymorphic_derived1.hpp simple class test + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <boost/serialization/access.hpp> +#include <boost/serialization/nvp.hpp> +#include <boost/serialization/base_object.hpp> +#include <boost/serialization/type_info_implementation.hpp> +#include <boost/serialization/extended_type_info_no_rtti.hpp> + +#include "polymorphic_base.hpp" + +class polymorphic_derived1 : public polymorphic_base +{ + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive &ar, const unsigned int /* file_version */){ + ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(polymorphic_base); + } +public: + virtual const char * get_key() const ; +}; + +BOOST_CLASS_EXPORT_KEY(polymorphic_derived1) + +BOOST_CLASS_TYPE_INFO( + polymorphic_derived1, + extended_type_info_no_rtti<polymorphic_derived1> +) + +#endif // POLYMORPHIC_DERIVED1_HPP diff --git a/src/boost/libs/serialization/test/polymorphic_derived2.cpp b/src/boost/libs/serialization/test/polymorphic_derived2.cpp new file mode 100644 index 00000000..20ee780b --- /dev/null +++ b/src/boost/libs/serialization/test/polymorphic_derived2.cpp @@ -0,0 +1,52 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// polymorphic_derived2.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <boost/serialization/type_info_implementation.hpp> +#include <boost/serialization/extended_type_info_no_rtti.hpp> +#include <boost/serialization/export.hpp> + +#include "polymorphic_base.hpp" +#include "polymorphic_derived2.hpp" + +template<class Archive> +POLYMORPHIC_DERIVED2_DLL_DECL void polymorphic_derived2::serialize( + Archive &ar, + const unsigned int /* file_version */ +){ + ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(polymorphic_base); +} + +const char * polymorphic_derived2::get_key() const { + return "polymorphic_derived2"; +} +POLYMORPHIC_DERIVED2_DLL_DECL +polymorphic_derived2::polymorphic_derived2(){} +POLYMORPHIC_DERIVED2_DLL_DECL +polymorphic_derived2::~polymorphic_derived2(){} + +#include <boost/archive/polymorphic_oarchive.hpp> +#include <boost/archive/polymorphic_iarchive.hpp> + +template +POLYMORPHIC_DERIVED2_DLL_DECL void polymorphic_derived2::serialize( + boost::archive::polymorphic_oarchive &, + const unsigned int /* file_version */ +); +template +POLYMORPHIC_DERIVED2_DLL_DECL void polymorphic_derived2::serialize( + boost::archive::polymorphic_iarchive &, + const unsigned int +); + +// MWerks users can do this to make their code work +BOOST_SERIALIZATION_MWERKS_BASE_AND_DERIVED(polymorphic_base, polymorphic_derived2) + +// note: export has to be AFTER #includes for all archive classes +BOOST_CLASS_EXPORT_IMPLEMENT(polymorphic_derived2) diff --git a/src/boost/libs/serialization/test/polymorphic_derived2.hpp b/src/boost/libs/serialization/test/polymorphic_derived2.hpp new file mode 100644 index 00000000..8c6b1c03 --- /dev/null +++ b/src/boost/libs/serialization/test/polymorphic_derived2.hpp @@ -0,0 +1,71 @@ +#ifndef BOOST_SERIALIZATION_TEST_POLYMORPHIC_DERIVED2_HPP +#define BOOST_SERIALIZATION_TEST_POLYMORPHIC_DERIVED2_HPP + +// MS compatible compilers support #pragma once +#if defined(_MSC_VER) +# pragma once +#endif + +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// polymorphic_derived2.hpp simple class test + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <boost/config.hpp> + +#include <boost/serialization/access.hpp> +#include <boost/serialization/nvp.hpp> +#include <boost/serialization/base_object.hpp> +#include <boost/serialization/type_info_implementation.hpp> +#include <boost/serialization/extended_type_info_typeid.hpp> + +#if defined(POLYMORPHIC_DERIVED2_IMPORT) + #define POLYMORPHIC_DERIVED2_DLL_DECL BOOST_SYMBOL_IMPORT + #pragma message ("polymorphic_derived2 imported") +#elif defined(POLYMORPHIC_DERIVED2_EXPORT) + #define POLYMORPHIC_DERIVED2_DLL_DECL BOOST_SYMBOL_EXPORT + #pragma message ("polymorphic_derived2 exported") +#endif + +#ifndef POLYMORPHIC_DERIVED2_DLL_DECL + #define POLYMORPHIC_DERIVED2_DLL_DECL +#endif + +#define POLYMORPHIC_BASE_IMPORT +#include "polymorphic_base.hpp" + +class BOOST_SYMBOL_VISIBLE polymorphic_derived2 : + public polymorphic_base +{ + friend class boost::serialization::access; + template<class Archive> + POLYMORPHIC_DERIVED2_DLL_DECL void serialize( + Archive &ar, + const unsigned int /* file_version */ + ); + POLYMORPHIC_DERIVED2_DLL_DECL const char * get_key() const; +public: + POLYMORPHIC_DERIVED2_DLL_DECL polymorphic_derived2(); + POLYMORPHIC_DERIVED2_DLL_DECL ~polymorphic_derived2(); +}; + +// we use this because we want to assign a key to this type +// but we don't want to explicitly instantiate code every time +// we do so!!!. If we don't do this, we end up with the same +// code in BOTH the DLL which implements polymorphic_derived2 +// as well as the main program. +BOOST_CLASS_EXPORT_KEY(polymorphic_derived2) + +// note the mixing of type_info systems is supported. +BOOST_CLASS_TYPE_INFO( + polymorphic_derived2, + boost::serialization::extended_type_info_typeid<polymorphic_derived2> +) + +#endif // BOOST_SERIALIZATION_TEST_POLYMORPHIC_DERIVED2_HPP + diff --git a/src/boost/libs/serialization/test/polymorphic_text_archive.hpp b/src/boost/libs/serialization/test/polymorphic_text_archive.hpp new file mode 100644 index 00000000..adf2e00d --- /dev/null +++ b/src/boost/libs/serialization/test/polymorphic_text_archive.hpp @@ -0,0 +1,12 @@ +// (C) Copyright 2002-4 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. +#include <boost/archive/polymorphic_text_oarchive.hpp> +typedef boost::archive::polymorphic_text_oarchive test_oarchive; +typedef std::ofstream test_ostream; +#include <boost/archive/polymorphic_text_iarchive.hpp> +typedef boost::archive::polymorphic_text_iarchive test_iarchive; +typedef std::ifstream test_istream; diff --git a/src/boost/libs/serialization/test/polymorphic_text_warchive.hpp b/src/boost/libs/serialization/test/polymorphic_text_warchive.hpp new file mode 100644 index 00000000..7bca23bf --- /dev/null +++ b/src/boost/libs/serialization/test/polymorphic_text_warchive.hpp @@ -0,0 +1,17 @@ +// (C) Copyright 2002-4 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. +#include <boost/config.hpp> +#ifdef BOOST_NO_STD_WSTREAMBUF +#error "wide char i/o not supported on this platform" +#else +#include <boost/archive/polymorphic_text_woarchive.hpp> +typedef boost::archive::polymorphic_text_woarchive test_oarchive; +typedef std::wofstream test_ostream; +#include <boost/archive/polymorphic_text_wiarchive.hpp> +typedef boost::archive::polymorphic_text_wiarchive test_iarchive; +typedef std::wifstream test_istream; +#endif diff --git a/src/boost/libs/serialization/test/polymorphic_xml_archive.hpp b/src/boost/libs/serialization/test/polymorphic_xml_archive.hpp new file mode 100644 index 00000000..163cb101 --- /dev/null +++ b/src/boost/libs/serialization/test/polymorphic_xml_archive.hpp @@ -0,0 +1,12 @@ +// (C) Copyright 2002-4 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. +#include <boost/archive/polymorphic_xml_oarchive.hpp> +typedef boost::archive::polymorphic_xml_oarchive test_oarchive; +typedef std::ofstream test_ostream; +#include <boost/archive/polymorphic_xml_iarchive.hpp> +typedef boost::archive::polymorphic_xml_iarchive test_iarchive; +typedef std::ifstream test_istream; diff --git a/src/boost/libs/serialization/test/polymorphic_xml_warchive.hpp b/src/boost/libs/serialization/test/polymorphic_xml_warchive.hpp new file mode 100644 index 00000000..581ec163 --- /dev/null +++ b/src/boost/libs/serialization/test/polymorphic_xml_warchive.hpp @@ -0,0 +1,12 @@ +// (C) Copyright 2002-4 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. +#include <boost/archive/polymorphic_xml_woarchive.hpp> +typedef boost::archive::polymorphic_xml_woarchive test_oarchive; +typedef std::wofstream test_ostream; +#include <boost/archive/polymorphic_xml_wiarchive.hpp> +typedef boost::archive::polymorphic_xml_wiarchive test_iarchive; +typedef std::wifstream test_istream; diff --git a/src/boost/libs/serialization/test/portable_binary_archive.hpp b/src/boost/libs/serialization/test/portable_binary_archive.hpp new file mode 100644 index 00000000..ce913316 --- /dev/null +++ b/src/boost/libs/serialization/test/portable_binary_archive.hpp @@ -0,0 +1,31 @@ +// (C) Copyright 2002-4 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. +// file includes for testing a custom archive. +// as an example this tests the portable binary archive + +#include <fstream> + +// #include output archive header +#include "../example/portable_binary_oarchive.hpp" +// define output archive class to be used +typedef portable_binary_oarchive test_oarchive; +// and corresponding stream +typedef std::ofstream test_ostream; + +// repeat the above for correspondng input archive +#include "../example/portable_binary_iarchive.hpp" +typedef portable_binary_iarchive test_iarchive; +typedef std::ifstream test_istream; + +// since this archive class isn't compiled into the +// boost serialization library, include this here +// so that things get instantiated +#include "../example/portable_binary_oarchive.cpp" +#include "../example/portable_binary_iarchive.cpp" + +// and stream open flags +#define TEST_STREAM_FLAGS std::ios::binary diff --git a/src/boost/libs/serialization/test/test3.dat b/src/boost/libs/serialization/test/test3.dat new file mode 100644 index 00000000..9aef7395 --- /dev/null +++ b/src/boost/libs/serialization/test/test3.dat @@ -0,0 +1 @@ + <?xml version="1.0" encoding="UTF-8" standalone="yes" ?> <!DOCTYPE boost_serialization> <boost_serialization signature="serialization::archive" version="3"> <a class_id="0" tracking_level="0"> <b>1</b> <f>96953204</f> <g>177129195</g> <l>1</l> <m>5627</m> <n>23010</n> <o>7419</o> <p>16212</p> <q>4086</q> <r>2749</r> <c>-33</c> <s>124</s> <t>28</t> <u>32225</u> <v>17543</v> <w>0.84431422</w> <x>1.0170664757130923</x> <y>tjbx</y> <z>cuwjentqpkejp</z> </a> </boost_serialization>
\ No newline at end of file diff --git a/src/boost/libs/serialization/test/test__helper.cpp b/src/boost/libs/serialization/test/test__helper.cpp new file mode 100644 index 00000000..0d68588e --- /dev/null +++ b/src/boost/libs/serialization/test/test__helper.cpp @@ -0,0 +1,160 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_polymorphic.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <cstddef> // NULL +#include <cstdio> // remove +#include <fstream> + +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +// the following is to ensure that when one of the libraries changes +// BJAM rebuilds and relinks the test. +/* +#include "polymorphic_text_archive.hpp" +#include "polymorphic_text_warchive.hpp" +#include "polymorphic_binary_archive.hpp" +#include "polymorphic_xml_archive.hpp" +#include "polymorphic_xml_warchive.hpp" +*/ + +#include <string> +#include <vector> + +#include "test_tools.hpp" +#include <boost/lexical_cast.hpp> +#include <boost/serialization/split_free.hpp> +#include <boost/serialization/vector.hpp> +#include <boost/serialization/nvp.hpp> +// this test uses a special string (my_string) whose contents are shared +// and hence saved in the archive only once. We need a helper in order +// to convert my_string into a serializable type + +class my_string:public std::string +{ + typedef std::string super; + +public: + my_string(){} + my_string(const super & str): super(str){} + my_string & operator=(const super& rhs) { + super::operator=(rhs); + return *this; + } +}; + +struct my_string_helper +{ + typedef std::vector<my_string> table; + table m_t; +}; + +BOOST_SERIALIZATION_SPLIT_FREE(my_string) + +namespace boost { +namespace serialization { + +template<class Archive> +void save(Archive & ar, const my_string & str, const unsigned int /* version */) +{ + void (* const idx)(Archive &, const my_string &, const unsigned int) = & save; + void * const id = reinterpret_cast<void * const>(idx); + my_string_helper & msh = ar.template get_helper<my_string_helper>(id); + + my_string_helper::table t = msh.m_t; + my_string_helper::table::iterator it = std::find(t.begin(), t.end(), str); + if(it == t.end()){ + my_string_helper::table::size_type s = t.size(); + ar << make_nvp("index", s); + t.push_back(str); + ar << make_nvp("string", static_cast<const std::string &>(str)); + } + else{ + my_string_helper::table::size_type s = it - t.begin(); + ar << make_nvp("index", s); + } +} + +template<class Archive> +void load(Archive & ar, my_string & str, const unsigned int /* version */) +{ + void (* const idx)(Archive &, my_string &, const unsigned int) = & load; + void * const id = reinterpret_cast<void * const>(idx); + my_string_helper & msh = ar.template get_helper<my_string_helper>(id); + + my_string_helper::table t = msh.m_t; + + my_string_helper::table::size_type s; + ar >> make_nvp("index", s); + t.reserve(s); + if(s >= t.size()){ + std::string tmp; + ar >> make_nvp("string", tmp); + str = tmp; + t.push_back(str); + } + else{ + str = t[s]; + } +} + +} // namespace serialization +} // namespace boost +#include <boost/archive/polymorphic_oarchive.hpp> +#include <boost/archive/polymorphic_iarchive.hpp> + +int test_main(int /* argc */, char * /* argv */ []) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + std::vector<my_string> v1; + for(int i=0; i<1000; ++i){ + v1.push_back(my_string(boost::lexical_cast<std::string>(i % 100))); + } + + // test using using polymorphic implementation. + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa_implementation(os, TEST_ARCHIVE_FLAGS); + oa_implementation << boost::serialization::make_nvp("vector", v1); + } + { + std::vector<my_string> v2; + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia_implementation(is, TEST_ARCHIVE_FLAGS); + ia_implementation >> boost::serialization::make_nvp("vector", v2); + BOOST_CHECK(v1 == v2); + } + std::remove(testfile); + + // test using using polymorphic interface. + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa_implementation(os, TEST_ARCHIVE_FLAGS); + boost::archive::polymorphic_oarchive & oa_interface = oa_implementation; + oa_interface << boost::serialization::make_nvp("vector", v1); + } + { + std::vector<my_string> v2; + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia_implementation(is, TEST_ARCHIVE_FLAGS); + boost::archive::polymorphic_iarchive & ia_interface = ia_implementation; + ia_interface >> boost::serialization::make_nvp("vector", v2); + BOOST_CHECK(v1 == v2); + } + std::remove(testfile); + std::remove(testfile); + return EXIT_SUCCESS; +} diff --git a/src/boost/libs/serialization/test/test_array.cpp b/src/boost/libs/serialization/test/test_array.cpp new file mode 100644 index 00000000..d5dbb88c --- /dev/null +++ b/src/boost/libs/serialization/test/test_array.cpp @@ -0,0 +1,92 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_array.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <stdlib.h> + +#include <boost/config.hpp> +#include <cstddef> +#include <fstream> +#include <algorithm> // equal +#include <cstdio> // remove +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif +#include "test_tools.hpp" +#include <boost/serialization/array.hpp> +#include <boost/core/no_exceptions_support.hpp> +#include <boost/archive/archive_exception.hpp> + +#include "A.hpp" +#include "A.ipp" + +template <class T> +int test_std_array(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + // test array of objects + const std::array<T, 10> a_array = {{T(),T(),T(),T(),T(),T(),T(),T(),T(),T()}}; + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("a_array", a_array); + } + { + std::array<T, 10> a_array1; + test_istream is(testfile, TEST_STREAM_FLAGS); + { + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("a_array", a_array1); + } + BOOST_CHECK(std::equal(a_array.begin(), a_array.end(), a_array1.begin())); + } + { + std::array<T, 9> a_array1; + test_istream is(testfile, TEST_STREAM_FLAGS); + { + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + bool exception_invoked = false; + BOOST_TRY { + ia >> boost::serialization::make_nvp("a_array", a_array1); + } + BOOST_CATCH (boost::archive::archive_exception const& ae){ + BOOST_CHECK( + boost::archive::archive_exception::array_size_too_short + == ae.code + ); + exception_invoked = true; + } + BOOST_CATCH_END + BOOST_CHECK(exception_invoked); + } + is.close(); + } + std::remove(testfile); + return EXIT_SUCCESS; +} + +int test_main( int /* argc */, char* /* argv */[] ){ + int res; + + // std array + res = test_std_array<A>(); + if (res != EXIT_SUCCESS) + return EXIT_FAILURE; + // test an int array for which optimized versions should be available + res = test_std_array<int>(); + if (res != EXIT_SUCCESS) + return EXIT_FAILURE; + + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_binary.cpp b/src/boost/libs/serialization/test/test_binary.cpp new file mode 100644 index 00000000..70b559f8 --- /dev/null +++ b/src/boost/libs/serialization/test/test_binary.cpp @@ -0,0 +1,167 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_simple_class.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <cstdlib> // for rand(), NULL, size_t + +#include <fstream> +#include <boost/config.hpp> + +#include <cstdio> // remove +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::rand; + using ::remove; +} +#endif + +#include "test_tools.hpp" + +#include <boost/serialization/nvp.hpp> +#include <boost/serialization/binary_object.hpp> + +class A { + friend class boost::serialization::access; + char data[150]; + // note: from an aesthetic perspective, I would much prefer to have this + // defined out of line. Unfortunately, this trips a bug in the VC 6.0 + // compiler. So hold our nose and put it her to permit running of tests. + template<class Archive> + void serialize(Archive & ar, const unsigned int /* file_version */){ + ar & boost::serialization::make_nvp( + "data", + boost::serialization::make_binary_object(data, sizeof(data)) + ); + } + +public: + A(); + bool operator==(const A & rhs) const; +}; + +A::A(){ + int i = sizeof(data); + while(i-- > 0) + data[i] = static_cast<char>(0xff & std::rand()); +} + +bool A::operator==(const A & rhs) const { + int i = sizeof(data); + while(i-- > 0) + if(data[i] != rhs.data[i]) + return false; + return true; +} + +int test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + const A a; + char s1[] = "a"; + char s2[] = "ab"; + char s3[] = "abc"; + char s4[] = "abcd"; + const int i = 12345; + + A a1; + char s1_1[10]; + char s1_2[10]; + char s1_3[10]; + char s1_4[10]; + int i1 = 34790; + + std::memset(s1_1, '\0', sizeof(s1_1)); + std::memset(s1_2, '\0', sizeof(s1_2)); + std::memset(s1_3, '\0', sizeof(s1_3)); + std::memset(s1_4, '\0', sizeof(s1_4)); + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp( + "s1", + boost::serialization::make_binary_object( + s1, + sizeof(s1) + ) + ); + oa << boost::serialization::make_nvp( + "s2", + boost::serialization::make_binary_object( + s2, + sizeof(s2) + ) + ); + oa << boost::serialization::make_nvp( + "s3", + boost::serialization::make_binary_object( + s3, + sizeof(s3) + ) + ); + oa << boost::serialization::make_nvp( + "s4", + boost::serialization::make_binary_object( + s4, + sizeof(s4) + ) + ); + oa << BOOST_SERIALIZATION_NVP(a); + // note: add a little bit on the end of the archive to detect + // failure of text mode binary. + oa << BOOST_SERIALIZATION_NVP(i); + } + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp( + "s1", + boost::serialization::make_binary_object( + s1_1, + sizeof(s1) + ) + ); + ia >> boost::serialization::make_nvp( + "s2", + boost::serialization::make_binary_object( + s1_2, + sizeof(s2) + ) + ); + ia >> boost::serialization::make_nvp( + "s3", + boost::serialization::make_binary_object( + s1_3, + sizeof(s3) + ) + ); + ia >> boost::serialization::make_nvp( + "s4", + boost::serialization::make_binary_object( + s1_4, + sizeof(s4) + ) + ); + ia >> BOOST_SERIALIZATION_NVP(a1); + // note: add a little bit on the end of the archive to detect + // failure of text mode binary. + ia >> BOOST_SERIALIZATION_NVP(i1); + } + BOOST_CHECK(0 == std::strcmp(s1, s1_1)); + BOOST_CHECK(0 == std::strcmp(s2, s1_2)); + BOOST_CHECK(0 == std::strcmp(s3, s1_3)); + BOOST_CHECK(0 == std::strcmp(s4, s1_4)); + BOOST_CHECK(a == a1); + BOOST_CHECK(i == i1); + std::remove(testfile); + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_bitset.cpp b/src/boost/libs/serialization/test/test_bitset.cpp new file mode 100644 index 00000000..db91829c --- /dev/null +++ b/src/boost/libs/serialization/test/test_bitset.cpp @@ -0,0 +1,64 @@ +// (C) Copyright 2009 Brian Ravnsgaard and Kenneth Riddile +// Use, modification and distribution are subject to the +// Boost Software License, Version 1.0. (See accompanying file +// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for most recent version including documentation. + +// Test that serialization of std::bitset works. +// Should pass compilation and execution +// 16.09.2004, updated 04.03.2009 + +#include <cstddef> // NULL +#include <cstdio> // remove +#include <fstream> + +#include <boost/config.hpp> + +#if defined( BOOST_NO_STDC_NAMESPACE ) +namespace std +{ + using ::remove; +} +#endif + +#include "test_tools.hpp" + +#include <boost/serialization/bitset.hpp> +#include <boost/serialization/nvp.hpp> + +int test_main( int /* argc */, char* /* argv */[] ) +{ + const char* testfile = boost::archive::tmpnam( NULL ); + BOOST_REQUIRE( NULL != testfile ); + + std::bitset<8> bitsetA; + bitsetA.set( 0, false ); + bitsetA.set( 1, true ); + bitsetA.set( 2, false ); + bitsetA.set( 3, true ); + bitsetA.set( 4, false ); + bitsetA.set( 5, false ); + bitsetA.set( 6, true ); + bitsetA.set( 7, true ); + + { + test_ostream os( testfile, TEST_STREAM_FLAGS ); + test_oarchive oa( os ); + oa << boost::serialization::make_nvp( "bitset", bitsetA ); + } + + std::bitset<8> bitsetB; + { + test_istream is( testfile, TEST_STREAM_FLAGS ); + test_iarchive ia( is ); + ia >> boost::serialization::make_nvp( "bitset", bitsetB ); + } + + BOOST_CHECK( bitsetA == bitsetB ); + + std::remove( testfile ); + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_boost_array.cpp b/src/boost/libs/serialization/test/test_boost_array.cpp new file mode 100644 index 00000000..29965641 --- /dev/null +++ b/src/boost/libs/serialization/test/test_boost_array.cpp @@ -0,0 +1,93 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_array.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <stdlib.h> + +#include <boost/config.hpp> +#include <cstddef> +#include <fstream> +#include <algorithm> // equal +#include <cstdio> // remove +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif +#include "test_tools.hpp" +#include <boost/core/no_exceptions_support.hpp> +#include <boost/archive/archive_exception.hpp> +#include <boost/serialization/boost_array.hpp> + +#include "A.hpp" +#include "A.ipp" + +template <class T> +int test_boost_array(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + // test array of objects + const boost::array<T,10> a_array = {{T(),T(),T(),T(),T(),T(),T(),T(),T(),T()}}; + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("a_array", a_array); + } + { + boost::array<T,10> a_array1; + test_istream is(testfile, TEST_STREAM_FLAGS); + { + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("a_array", a_array1); + } + is.close(); + BOOST_CHECK(std::equal(a_array.begin(), a_array.end(), a_array1.begin())); + } + { + boost::array<T, 9> a_array1; + test_istream is(testfile, TEST_STREAM_FLAGS); + { + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + bool exception_invoked = false; + BOOST_TRY { + ia >> boost::serialization::make_nvp("a_array", a_array1); + } + BOOST_CATCH (boost::archive::archive_exception const& ae){ + BOOST_CHECK( + boost::archive::archive_exception::array_size_too_short + == ae.code + ); + exception_invoked = true; + } + BOOST_CATCH_END + BOOST_CHECK(exception_invoked); + } + is.close(); + } + std::remove(testfile); + return EXIT_SUCCESS; +} + +int test_main( int /* argc */, char* /* argv */[] ){ + int res; + + // boost array + res = test_boost_array<A>(); + if (res != EXIT_SUCCESS) + return EXIT_FAILURE; + // test an int array for which optimized versions should be available + res = test_boost_array<int>(); + if (res != EXIT_SUCCESS) + return EXIT_FAILURE; + + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_check.cpp b/src/boost/libs/serialization/test/test_check.cpp new file mode 100644 index 00000000..2a6967c1 --- /dev/null +++ b/src/boost/libs/serialization/test/test_check.cpp @@ -0,0 +1,145 @@ +// (C) Copyright 2009 Robert Ramey +// Use, modification and distribution are subject to the +// Boost Software License, Version 1.0. (See accompanying file +// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for most recent version including documentation. + +// note: this is a compile only test. +#include <sstream> +#include <boost/config.hpp> // BOOST_STATIC_CONST + +#include <boost/serialization/static_warning.hpp> +#include <boost/serialization/tracking.hpp> +#include <boost/serialization/level.hpp> +#include <boost/serialization/version.hpp> +#include <boost/serialization/nvp.hpp> + +#include <boost/archive/text_iarchive.hpp> +#include <boost/archive/text_oarchive.hpp> + +// track_selectivly with class information in the archive +// is unsafe when used with a pointer and should trigger a warning +struct check1 { + template<class Archive> + void serialize(Archive & ar, const unsigned int version); + check1(){} +}; + +BOOST_CLASS_IMPLEMENTATION(check1, boost::serialization::object_serializable) +BOOST_CLASS_TRACKING(check1, boost::serialization::track_selectively) + +// the combination of versioning + no class information +// should trigger a warning +struct check2 { + template<class Archive> + void serialize(Archive & ar, const unsigned int version); + check2(){} +}; + +BOOST_CLASS_IMPLEMENTATION(check2, boost::serialization::object_serializable) +BOOST_CLASS_VERSION(check2, 1) +// use track always to turn off warning tested above +BOOST_CLASS_TRACKING(check2, boost::serialization::track_always) + +// serializing a type marked as "track_never" through a pointer +// is likely an error +struct check3 { + template<class Archive> + void serialize(Archive & ar, const unsigned int version); + check3(){} +}; + +BOOST_CLASS_TRACKING(check3, boost::serialization::track_never) + +template<class T> +int f(){ + BOOST_STATIC_WARNING(T::value); + BOOST_STATIC_ASSERT(T::value); + return 0; +} + +///////////////////////////////////////////////////////////////////////// +// compilation of this program should show a total of 10 warning messages +int main(int /* argc */, char * /* argv */[]){ + std::stringstream s; + { + boost::archive::text_oarchive oa(s); + + check1 const c1_out; + oa << c1_out; + + check1 c1_non_const_out; + oa << c1_non_const_out; // warn check_object_tracking + + check1 * const c1_ptr_out = 0; + oa << c1_ptr_out; // warn check_pointer_level + + check2 const * c2_ptr_out; + oa << c2_ptr_out; // error check_object_versioning + + check3 * const c3_ptr_out = 0; + oa << c3_ptr_out; // warning check_pointer_tracking + + check2 const c2_out; + oa << c2_out; // error check_object_versioning + } + { + boost::archive::text_iarchive ia(s); + + check1 const c1_in; + ia >> c1_in; // check_const_loading + + check1 * c1_ptr_in = 0; + ia >> c1_ptr_in; // warn check_pointer_level + + check2 * c2_ptr_in; + ia >> c2_ptr_in; // error check_object_versioning + + check3 * c3_ptr_in = 0; + ia >> c3_ptr_in; // warning check_pointer_tracking + + check2 c2_in; + ia >> c2_in; // error check_object_versioning + } + { + boost::archive::text_oarchive oa(s); + + check1 const c1_out; + oa << BOOST_SERIALIZATION_NVP(c1_out); + + check1 c1_non_const_out; + oa << BOOST_SERIALIZATION_NVP(c1_non_const_out); // warn check_object_tracking + + check1 * const c1_ptr_out = 0; + oa << BOOST_SERIALIZATION_NVP(c1_ptr_out); // warn check_pointer_level + + check2 const * c2_ptr_out; + oa << BOOST_SERIALIZATION_NVP(c2_ptr_out); // error check_object_versioning + + check3 * const c3_ptr_out = 0; + oa << BOOST_SERIALIZATION_NVP(c3_ptr_out); // warning check_pointer_tracking + + check2 const c2_out; + oa << BOOST_SERIALIZATION_NVP(c2_out); // error check_object_versioning + } + { + boost::archive::text_iarchive ia(s); + + check1 const c1_in; + ia >> BOOST_SERIALIZATION_NVP(c1_in); // check_const_loading + + check1 * c1_ptr_in = 0; + ia >> BOOST_SERIALIZATION_NVP(c1_ptr_in); // warn check_pointer_level + + check2 * c2_ptr_in; + ia >> BOOST_SERIALIZATION_NVP(c2_ptr_in); // error check_object_versioning + + check3 * c3_ptr_in = 0; + ia >> BOOST_SERIALIZATION_NVP(c3_ptr_in); // warning check_pointer_tracking + + check2 c2_in; + ia >> BOOST_SERIALIZATION_NVP(c2_in); // error check_object_versioning + } + return 0; +} diff --git a/src/boost/libs/serialization/test/test_class_info_load.cpp b/src/boost/libs/serialization/test/test_class_info_load.cpp new file mode 100644 index 00000000..af153294 --- /dev/null +++ b/src/boost/libs/serialization/test/test_class_info_load.cpp @@ -0,0 +1,92 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_class_info_load.cpp: test implementation level trait + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// test implementation level "object_class_info" +// should pass compilation and execution + +#include <string> +#include <fstream> + +#include <boost/archive/tmpdir.hpp> +#include <boost/preprocessor/stringize.hpp> +#include "test_tools.hpp" + +#include <boost/static_assert.hpp> +#include <boost/serialization/level.hpp> +#include <boost/serialization/tracking.hpp> +#include <boost/serialization/version.hpp> +#include <boost/serialization/nvp.hpp> + +class A +{ + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive & /*ar*/, const unsigned int file_version){ + // class that don't save class info always have a version number of 0 + BOOST_CHECK(file_version == 0); + BOOST_STATIC_ASSERT(0 == ::boost::serialization::version<A>::value); + ++count; + } +public: + unsigned int count; + A() : count(0) {} +}; + +BOOST_CLASS_IMPLEMENTATION(A, ::boost::serialization::object_serializable) +BOOST_CLASS_TRACKING(A, ::boost::serialization::track_never) + +// second case : serialize WITH class information +class B +{ + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive & /*ar*/, const unsigned int file_version){ + // verify at execution that the version number corresponds to the saved + // one + BOOST_CHECK(file_version == 2); + ++count; + } +public: + unsigned int count; + B() : count(0) {} +}; + +BOOST_CLASS_IMPLEMENTATION(B, ::boost::serialization::object_class_info) +BOOST_CLASS_TRACKING(B, ::boost::serialization::track_never) +BOOST_CLASS_VERSION(B, 4) + +void in(const char *testfile, A & a, B & b) +{ + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> BOOST_SERIALIZATION_NVP(a); + ia >> BOOST_SERIALIZATION_NVP(a); + BOOST_CHECK(a.count == 2); // no tracking => redundant loads + ia >> BOOST_SERIALIZATION_NVP(b); + ia >> BOOST_SERIALIZATION_NVP(b); + // note: archive was saved with tracking so that is what determines + // whether tracking is perform on load - regardless of the latest + // tracking setting. + BOOST_CHECK(b.count == 1); +} + +int +test_main( int /* argc */, char* /* argv */[] ) +{ + A a; + B b; + std::string filename; + filename += boost::archive::tmpdir(); + filename += '/'; + filename += BOOST_PP_STRINGIZE(testfile_); + filename += BOOST_PP_STRINGIZE(BOOST_ARCHIVE_TEST); + in(filename.c_str(), a, b); + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_class_info_save.cpp b/src/boost/libs/serialization/test/test_class_info_save.cpp new file mode 100644 index 00000000..dc02876c --- /dev/null +++ b/src/boost/libs/serialization/test/test_class_info_save.cpp @@ -0,0 +1,100 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_class_info_save.cpp: test implementation level trait + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// test implementation level "object_class_info" +// should pass compilation and execution + +#include <fstream> +#include <string> + +#include <boost/static_assert.hpp> +#include <boost/archive/tmpdir.hpp> +#include <boost/preprocessor/stringize.hpp> +#include "test_tools.hpp" + +#include <boost/serialization/level.hpp> +#include <boost/serialization/version.hpp> +#include <boost/serialization/tracking.hpp> +#include <boost/serialization/nvp.hpp> + +// first case : serialize WITHOUT class information +class A +{ + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive & /*ar*/, const unsigned int file_version){ + // class that don't save class info always have a version number of 0 + BOOST_CHECK(file_version == 0); + BOOST_STATIC_ASSERT(0 == ::boost::serialization::version<A>::value); + ++count; + } +public: + unsigned int count; + A() : count(0) {} +}; + +BOOST_CLASS_IMPLEMENTATION(A, ::boost::serialization::object_serializable) +BOOST_CLASS_TRACKING(A, ::boost::serialization::track_never) + +// second case : serialize WITH class information +// note: GCC compile fails if this is after the class declaration +class B; +BOOST_CLASS_VERSION(B, 2) + +class B +{ + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive & /*ar*/, const unsigned int file_version){ + // verify at execution that correct version number is passed on save + BOOST_CHECK( + static_cast<const int>(file_version) + == ::boost::serialization::version<B>::value + ); + ++count; + } +public: + unsigned int count; + B() : count(0) {} +}; + +BOOST_CLASS_IMPLEMENTATION(B, ::boost::serialization::object_class_info) +BOOST_CLASS_TRACKING(B, boost::serialization::track_always) + +#include <iostream> + +void out(const char *testfile, const A & a, const B & b) +{ + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + // write object twice to check tracking + oa << BOOST_SERIALIZATION_NVP(a); + oa << BOOST_SERIALIZATION_NVP(a); + BOOST_CHECK(a.count == 2); // no tracking => redundant saves + std::cout << "a.count=" << a.count << '\n' ; + oa << BOOST_SERIALIZATION_NVP(b); + oa << BOOST_SERIALIZATION_NVP(b); + BOOST_CHECK(b.count == 1); // tracking => no redundant saves + std::cout << "b.count=" << b.count << '\n' ; +} + +int +test_main( int /* argc */, char* /* argv */[] ) +{ + A a; + B b; + std::string filename; + filename += boost::archive::tmpdir(); + filename += '/'; + filename += BOOST_PP_STRINGIZE(testfile_); + filename += BOOST_PP_STRINGIZE(BOOST_ARCHIVE_TEST); + out(filename.c_str(), a, b); + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_codecvt_null.cpp b/src/boost/libs/serialization/test/test_codecvt_null.cpp new file mode 100644 index 00000000..475319fd --- /dev/null +++ b/src/boost/libs/serialization/test/test_codecvt_null.cpp @@ -0,0 +1,124 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_codecvt_null.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution. Note: compilation with compilers +// which use wchar_t as 2 byte objects will emit warnings. These should be +// ignored. + +#include <algorithm> // std::copy +#include <fstream> +#include <iostream> +#include <iterator> +#include <locale> +#include <vector> +#include <cstdio> // remove +#include <cstddef> // NULL, size_t + +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include "test_tools.hpp" + +#include <boost/archive/codecvt_null.hpp> +#include <boost/archive/iterators/ostream_iterator.hpp> +#include <boost/archive/iterators/istream_iterator.hpp> + +template<std::size_t S> +struct test_data +{ + static wchar_t wchar_encoding[]; +}; + +template<> +wchar_t test_data<2>::wchar_encoding[] = { + (wchar_t) 0x0001, + (wchar_t) 0x007f, + (wchar_t) 0x0080, + (wchar_t) 0x07ff, + (wchar_t) 0x0800, + (wchar_t) 0x7fff +}; + +template<> +wchar_t test_data<4>::wchar_encoding[] = { + (wchar_t) 0x00000001, + (wchar_t) 0x0000007f, + (wchar_t) 0x00000080, + (wchar_t) 0x000007ff, + (wchar_t) 0x00000800, + (wchar_t) 0x0000ffff, + (wchar_t) 0x00010000, + (wchar_t) 0x0010ffff, + (wchar_t) 0x001fffff, + (wchar_t) 0x00200000, + (wchar_t) 0x03ffffff, + (wchar_t) 0x04000000, + (wchar_t) 0x7fffffff +}; + +#include <iostream> + +int test_main( int /* argc */, char* /* argv */[] ) { + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + std::locale old_loc; + std::locale null_locale = std::locale( + old_loc, + new boost::archive::codecvt_null<wchar_t> + ); + + typedef test_data<sizeof(wchar_t)> td; + { + std::wofstream ofs; + ofs.imbue(null_locale); + ofs.open(testfile, std::ios::binary); + std::copy( + td::wchar_encoding, + td::wchar_encoding + sizeof(td::wchar_encoding)/sizeof(wchar_t), + boost::archive::iterators::ostream_iterator<wchar_t>(ofs) + ); + } + bool ok = false; + { + std::wifstream ifs; + ifs.imbue(null_locale); + ifs.open(testfile, std::ios::binary); + ok = std::equal( + td::wchar_encoding, + td::wchar_encoding + sizeof(td::wchar_encoding)/sizeof(wchar_t), + boost::archive::iterators::istream_iterator<wchar_t>(ifs) + ); + } + + BOOST_CHECK(ok); + { + std::wofstream ofs("testfile2"); + ofs.imbue(null_locale); + int i = 10; + ofs << i; + ofs.close(); + + std::wifstream ifs("testfile2"); + ifs.imbue(null_locale); + int i2; + ifs >> i2; + std::cout << "i=" << i << std::endl; + std::cout << "i2=" << i2 << std::endl; + BOOST_CHECK(i == i2); + ifs.close(); + } + + std::remove(testfile); + return EXIT_SUCCESS; +} + diff --git a/src/boost/libs/serialization/test/test_complex.cpp b/src/boost/libs/serialization/test/test_complex.cpp new file mode 100644 index 00000000..6776f7b2 --- /dev/null +++ b/src/boost/libs/serialization/test/test_complex.cpp @@ -0,0 +1,82 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_complex.cpp + +// (C) Copyright 2005 Matthias Troyer . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <fstream> + +#include <cstddef> // NULL +#include <cstdlib> // rand +#include <cstdio> // remove +#include <boost/config.hpp> +#include <boost/detail/workaround.hpp> +#include <boost/math/special_functions/next.hpp> + +#if defined(BOOST_NO_STDC_NAMESPACE) +#include <boost/limits.hpp> +namespace std{ + using ::rand; + using ::remove; + #if BOOST_WORKAROUND(BOOST_MSVC, >= 1400) && !defined(UNDER_CE) + using ::numeric_limits; + #endif +} +#endif + +#include "test_tools.hpp" + +#include <boost/preprocessor/stringize.hpp> +#include BOOST_PP_STRINGIZE(BOOST_ARCHIVE_TEST) + +#include <boost/serialization/complex.hpp> + +#include <iostream> + +int test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + // test array of objects + std::complex<float> a( + static_cast<float>(std::rand()) / static_cast<float>(std::rand()), + static_cast<float>(std::rand()) / static_cast<float>(std::rand()) + ); + std::complex<double> b( + static_cast<double>(std::rand()) / static_cast<double>(std::rand()), + static_cast<double>(std::rand()) / static_cast<double>(std::rand()) + ); + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os); + oa << boost::serialization::make_nvp("afloatcomplex", a); + oa << boost::serialization::make_nvp("adoublecomplex", b); + } + std::complex<float> a1; + std::complex<double> b1; + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is); + ia >> boost::serialization::make_nvp("afloatcomplex", a1); + ia >> boost::serialization::make_nvp("adoublecomplex", b1); + } + + std::cerr << "a.real()-a1a.real() distance = " << std::abs( boost::math::float_distance(a.real(), a1.real())) << std::endl; + BOOST_CHECK(std::abs(boost::math::float_distance(a.real(), a1.real())) < 2); + std::cerr << "a.imag() - a1a.imag() distance = " << std::abs( boost::math::float_distance(a.imag(), a1.imag())) << std::endl; + BOOST_CHECK(std::abs(boost::math::float_distance(a.imag(), a1.imag())) < 2); + std::cerr << "b.real() - b1.real() distance = " << std::abs( boost::math::float_distance(b.real(), b1.real())) << std::endl; + BOOST_CHECK(std::abs(boost::math::float_distance(b.real(), b1.real())) < 2); + std::cerr << "b.imag() - b1.imag() distance = " << std::abs( boost::math::float_distance(b.imag(), b1.imag())) << std::endl; + BOOST_CHECK(std::abs(boost::math::float_distance(b.imag(), b1.imag())) < 2); + + std::remove(testfile); + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_const_load_fail1.cpp b/src/boost/libs/serialization/test/test_const_load_fail1.cpp new file mode 100644 index 00000000..3c5c0304 --- /dev/null +++ b/src/boost/libs/serialization/test/test_const_load_fail1.cpp @@ -0,0 +1,23 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_const.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// compile only + +#include <boost/archive/text_iarchive.hpp> + +using namespace boost::archive; + +struct A { + template<class Archive> + void serialize(Archive & ar, unsigned int version) { + } +}; + +void f1(text_iarchive & ia, const A & a){ + ia >> a; +} diff --git a/src/boost/libs/serialization/test/test_const_load_fail1_nvp.cpp b/src/boost/libs/serialization/test/test_const_load_fail1_nvp.cpp new file mode 100644 index 00000000..f9ba9b3d --- /dev/null +++ b/src/boost/libs/serialization/test/test_const_load_fail1_nvp.cpp @@ -0,0 +1,24 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_const.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// compile only + +#include <boost/archive/text_iarchive.hpp> +#include <boost/serialization/nvp.hpp> + +using namespace boost::archive; + +struct A { + template<class Archive> + void serialize(Archive & ar, unsigned int version) { + } +}; + +void f1(text_iarchive & ia, const A & a){ + ia >> BOOST_SERIALIZATION_NVP(a); +} diff --git a/src/boost/libs/serialization/test/test_const_load_fail2.cpp b/src/boost/libs/serialization/test/test_const_load_fail2.cpp new file mode 100644 index 00000000..7d9b976a --- /dev/null +++ b/src/boost/libs/serialization/test/test_const_load_fail2.cpp @@ -0,0 +1,23 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_const.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// compile only + +#include <boost/archive/text_iarchive.hpp> + +using namespace boost::archive; + +struct A { + template<class Archive> + void serialize(Archive & ar, unsigned int version) { + } +}; + +void f2(text_iarchive & ia, A * const & a){ + ia >> a; +} diff --git a/src/boost/libs/serialization/test/test_const_load_fail2_nvp.cpp b/src/boost/libs/serialization/test/test_const_load_fail2_nvp.cpp new file mode 100644 index 00000000..600461c0 --- /dev/null +++ b/src/boost/libs/serialization/test/test_const_load_fail2_nvp.cpp @@ -0,0 +1,25 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_const.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// compile only + +#include <boost/archive/text_iarchive.hpp> +#include <boost/serialization/nvp.hpp> + +using namespace boost::archive; + +struct A { + template<class Archive> + void serialize(Archive & ar, unsigned int version) { + } +}; + +void f2(text_iarchive & ia, A * const & a){ + ia >> BOOST_SERIALIZATION_NVP(a); +} + diff --git a/src/boost/libs/serialization/test/test_const_load_fail3.cpp b/src/boost/libs/serialization/test/test_const_load_fail3.cpp new file mode 100644 index 00000000..4f385eb0 --- /dev/null +++ b/src/boost/libs/serialization/test/test_const_load_fail3.cpp @@ -0,0 +1,22 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_const.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// compile only + +#include <boost/archive/text_iarchive.hpp> +using namespace boost::archive; + +struct A { + template<class Archive> + void serialize(Archive & ar, unsigned int version) { + } +}; + +void f2(text_iarchive & ia, const A * const & a){ + ia >> a; +} diff --git a/src/boost/libs/serialization/test/test_const_load_fail3_nvp.cpp b/src/boost/libs/serialization/test/test_const_load_fail3_nvp.cpp new file mode 100644 index 00000000..e8ef913d --- /dev/null +++ b/src/boost/libs/serialization/test/test_const_load_fail3_nvp.cpp @@ -0,0 +1,24 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_const.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// compile only + +#include <boost/archive/text_iarchive.hpp> +#include <boost/serialization/nvp.hpp> + +using namespace boost::archive; + +struct A { + template<class Archive> + void serialize(Archive & ar, unsigned int version) { + } +}; + +void f2(text_iarchive & ia, const A * const & a){ + ia >> BOOST_SERIALIZATION_NVP(a); +} diff --git a/src/boost/libs/serialization/test/test_const_pass.cpp b/src/boost/libs/serialization/test/test_const_pass.cpp new file mode 100644 index 00000000..211ffdd4 --- /dev/null +++ b/src/boost/libs/serialization/test/test_const_pass.cpp @@ -0,0 +1,54 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_const.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// compile only + +#include <boost/archive/text_oarchive.hpp> +#include <boost/archive/text_iarchive.hpp> +#include <boost/serialization/nvp.hpp> + +struct A { + template<class Archive> + void serialize(Archive & ar, unsigned int version) { + } +}; + +// should compile w/o problem +void f1(boost::archive::text_oarchive & oa, const A & a){ + oa & a; + oa & BOOST_SERIALIZATION_NVP(a); + oa << a; + oa << BOOST_SERIALIZATION_NVP(a); +} +void f2(boost::archive::text_oarchive & oa, const A * const & a){ + oa & a; + oa & BOOST_SERIALIZATION_NVP(a); + oa << a; + oa << BOOST_SERIALIZATION_NVP(a); +} +void f3(boost::archive::text_iarchive & ia, A & a){ + ia & a; + ia & BOOST_SERIALIZATION_NVP(a); + ia >> a; + ia >> BOOST_SERIALIZATION_NVP(a); +} +void f4(boost::archive::text_iarchive & ia, A * & a){ + ia & a; + ia & BOOST_SERIALIZATION_NVP(a); + ia >> a; + ia >> BOOST_SERIALIZATION_NVP(a); +} +#if 0 +void f5(boost::archive::text_oarchive & oa, const A * & a){ + oa & a; + oa & BOOST_SERIALIZATION_NVP(a); + oa << a; + oa << BOOST_SERIALIZATION_NVP(a); +} +#endif + diff --git a/src/boost/libs/serialization/test/test_const_save_warn1.cpp b/src/boost/libs/serialization/test/test_const_save_warn1.cpp new file mode 100644 index 00000000..185f0073 --- /dev/null +++ b/src/boost/libs/serialization/test/test_const_save_warn1.cpp @@ -0,0 +1,25 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_const.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// compile only + +#include <boost/archive/text_oarchive.hpp> + +using namespace boost::archive; + +struct A { + template<class Archive> + void serialize(Archive & ar, unsigned int version) { + } +}; + +// should fail to compile +void f1(text_oarchive & oa, A & a){ + oa << a; +} + diff --git a/src/boost/libs/serialization/test/test_const_save_warn1_nvp.cpp b/src/boost/libs/serialization/test/test_const_save_warn1_nvp.cpp new file mode 100644 index 00000000..19e7c277 --- /dev/null +++ b/src/boost/libs/serialization/test/test_const_save_warn1_nvp.cpp @@ -0,0 +1,26 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_const.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// compile only + +#include <boost/archive/text_oarchive.hpp> +#include <boost/serialization/nvp.hpp> +#include <boost/serialization/tracking.hpp> + +using namespace boost::archive; + +struct A { + template<class Archive> + void serialize(Archive & ar, unsigned int version) { + } +}; + +void f1(text_oarchive & oa, A & a){ + oa << BOOST_SERIALIZATION_NVP(a); +} + diff --git a/src/boost/libs/serialization/test/test_const_save_warn2.cpp b/src/boost/libs/serialization/test/test_const_save_warn2.cpp new file mode 100644 index 00000000..0a77b720 --- /dev/null +++ b/src/boost/libs/serialization/test/test_const_save_warn2.cpp @@ -0,0 +1,24 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_const.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// compile only + +#include <boost/archive/text_oarchive.hpp> + +using namespace boost::archive; + +struct A { + template<class Archive> + void serialize(Archive & ar, unsigned int version) { + } +}; + +void f2(text_oarchive & oa, A * & a){ + oa << a; +} + diff --git a/src/boost/libs/serialization/test/test_const_save_warn2_nvp.cpp b/src/boost/libs/serialization/test/test_const_save_warn2_nvp.cpp new file mode 100644 index 00000000..7b887c5d --- /dev/null +++ b/src/boost/libs/serialization/test/test_const_save_warn2_nvp.cpp @@ -0,0 +1,25 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_const.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// compile only + +#include <boost/archive/text_oarchive.hpp> +#include <boost/serialization/nvp.hpp> + +using namespace boost::archive; + +struct A { + template<class Archive> + void serialize(Archive & ar, unsigned int version) { + } +}; + +void f2(text_oarchive & oa, A * & a){ + oa << BOOST_SERIALIZATION_NVP(a); +} + diff --git a/src/boost/libs/serialization/test/test_const_save_warn3.cpp b/src/boost/libs/serialization/test/test_const_save_warn3.cpp new file mode 100644 index 00000000..19c14967 --- /dev/null +++ b/src/boost/libs/serialization/test/test_const_save_warn3.cpp @@ -0,0 +1,24 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_const.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// compile only + +#include <boost/archive/text_oarchive.hpp> + +using namespace boost::archive; + +struct A { + template<class Archive> + void serialize(Archive & ar, unsigned int version) { + } +}; + +void f3(text_oarchive & oa, const A * & a){ + oa << a; +} + diff --git a/src/boost/libs/serialization/test/test_const_save_warn3_nvp.cpp b/src/boost/libs/serialization/test/test_const_save_warn3_nvp.cpp new file mode 100644 index 00000000..7571b3c6 --- /dev/null +++ b/src/boost/libs/serialization/test/test_const_save_warn3_nvp.cpp @@ -0,0 +1,25 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_const.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// compile only + +#include <boost/archive/text_oarchive.hpp> +#include <boost/serialization/nvp.hpp> + +using namespace boost::archive; + +struct A { + template<class Archive> + void serialize(Archive & ar, unsigned int version) { + } +}; + +void f3(text_oarchive & oa, const A * & a){ + oa << BOOST_SERIALIZATION_NVP(a); +} + diff --git a/src/boost/libs/serialization/test/test_const_save_warn4.cpp b/src/boost/libs/serialization/test/test_const_save_warn4.cpp new file mode 100644 index 00000000..c9599aaa --- /dev/null +++ b/src/boost/libs/serialization/test/test_const_save_warn4.cpp @@ -0,0 +1,37 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_const.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// compile only + +#include <boost/archive/text_oarchive.hpp> +#include <boost/serialization/nvp.hpp> + +using namespace boost::archive; + +struct A { + template<class Archive> + void serialize(Archive & ar, unsigned int version) { + } +}; + +// comment out this test case as a reminder not to keep inserting it !!! +// we don't trap this as an error in order to permit things like +// X * xptr; +// save(..){ +// ar << xptr; +// } +// +// for rational - consider the following example from demo.cpp +// std::list<pair<trip_info, bus_route_info *> > schedule +// its not obvious to me how this can be cast to: +// std::list<pair<trip_info, const bus_route_info * const> > schedule + +void f4(text_oarchive & oa, A * const & a){ + oa << a; +} + diff --git a/src/boost/libs/serialization/test/test_const_save_warn4_nvp.cpp b/src/boost/libs/serialization/test/test_const_save_warn4_nvp.cpp new file mode 100644 index 00000000..9c61db61 --- /dev/null +++ b/src/boost/libs/serialization/test/test_const_save_warn4_nvp.cpp @@ -0,0 +1,39 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_const.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// compile only + +#include <boost/archive/text_oarchive.hpp> +#include <boost/serialization/nvp.hpp> + +using namespace boost::archive; + +struct A { + template<class Archive> + void serialize(Archive & ar, unsigned int version) { + } +}; + +// comment out this test case as a reminder not to keep inserting it !!! +// we don't trap this as an error in order to permit things like +// X * xptr; +// save(..){ +// ar << xptr; +// } +// +// for rational - consider the following example from demo.cpp +// +// std::list<pair<trip_info, bus_route_info *> > schedule +// +// its not obvious to me how this can be cast to: +// +// std::list<pair<trip_info, const bus_route_info * const> > schedule + +void f4(text_oarchive & oa, A * const & a){ + oa << BOOST_SERIALIZATION_NVP(a); +} diff --git a/src/boost/libs/serialization/test/test_contained_class.cpp b/src/boost/libs/serialization/test/test_contained_class.cpp new file mode 100644 index 00000000..5dc15e2f --- /dev/null +++ b/src/boost/libs/serialization/test/test_contained_class.cpp @@ -0,0 +1,69 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_contained_class.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <cstddef> +#include <fstream> + +#include <cstdio> // remove +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include "test_tools.hpp" +#include <boost/serialization/nvp.hpp> + +#include "B.hpp" +#include "A.ipp" + +/////////////////////////////////////////////////////// +// Contained class +class C +{ +private: + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive & ar, const unsigned int /* file_version */){ + ar & BOOST_SERIALIZATION_NVP(b); + } + B b; +public: + bool operator==(const C &rhs) const + { + return b == rhs.b; + } + C(){} +}; + +int test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + const C c; + C c1; + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("c", c); + } + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("c", c1); + } + BOOST_CHECK(c == c1); + std::remove(testfile); + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_cyclic_ptrs.cpp b/src/boost/libs/serialization/test/test_cyclic_ptrs.cpp new file mode 100644 index 00000000..365949df --- /dev/null +++ b/src/boost/libs/serialization/test/test_cyclic_ptrs.cpp @@ -0,0 +1,204 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_cyclic_ptrs.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <cstddef> // NULL +#include <fstream> + +#include <cstdio> // remove +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include "test_tools.hpp" +#include <boost/core/no_exceptions_support.hpp> + +#include <boost/serialization/nvp.hpp> +#include <boost/serialization/version.hpp> +#include <boost/serialization/base_object.hpp> + +#include "A.hpp" +#include "A.ipp" + +/////////////////////////////////////////////////////// +// class with a member which refers to itself +class J : public A +{ +private: + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive &ar, const unsigned int /* file_version */){ + ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(A); + ar & BOOST_SERIALIZATION_NVP(j); + } +public: + bool operator==(const J &rhs) const; + J *j; + J(J *_j) : j(_j) {} + J() : j(NULL){} +}; + +BOOST_CLASS_VERSION(J, 6) + +bool J::operator==(const J &rhs) const +{ + return static_cast<const A &>(*this) == static_cast<const A &>(rhs); +} + +/////////////////////////////////////////////////////// +// class with members that refer to each other +// this is an example of a class that, as written, cannot +// be serialized with this system. The problem is that the +// serialization of the first member - j1 , provokes serialization +// of those objects which it points to either directly or indirectly. +// When those objects are subsequently serialized, it is discovered +// that have already been serialized through pointers. This is +// detected by the system and an exception - pointer_conflict - +// is thrown. Permiting this to go undetected would result in the +// creation of multiple equal objects rather than the original +// structure. +class K +{ + J j1; + J j2; + J j3; + friend class boost::serialization::access; + template<class Archive> + void serialize( + Archive &ar, + const unsigned int /* file_version */ + ){ + ar & BOOST_SERIALIZATION_NVP(j1); + ar & BOOST_SERIALIZATION_NVP(j2); + ar & BOOST_SERIALIZATION_NVP(j3); + } +public: + bool operator==(const K &rhs) const; + K(); +}; + +K::K() +: j1(&j2), j2(&j3), j3(&j1) +{ +} + +bool K::operator==(const K &rhs) const +{ + return + j1.j == & j2 + && j2.j == & j3 + && j3.j == & j1 + && j1 == rhs.j1 + && j2 == rhs.j2 + && j3 == rhs.j3 + ; +} + +int test1(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + J j1, j2; + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << BOOST_SERIALIZATION_NVP(j1); + } + { + // try to read the archive + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> BOOST_SERIALIZATION_NVP(j2); + } + BOOST_CHECK(j1 == j2); + std::remove(testfile); + return EXIT_SUCCESS; +} + +int test2(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + J *j1 = new J; + j1->j = j1; + J *j2 = reinterpret_cast<J *>(0xBAADF00D); + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << BOOST_SERIALIZATION_NVP(j1); + } + { + // try to read the archive + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> BOOST_SERIALIZATION_NVP(j2); + } + BOOST_CHECK(*j1 == *j2); + delete j1; + BOOST_CHECK(j2 == j2->j); + std::remove(testfile); + return EXIT_SUCCESS; +} + +int test3(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + K k; + boost::archive::archive_exception exception( + boost::archive::archive_exception::no_exception + ); + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + BOOST_TRY { + oa << BOOST_SERIALIZATION_NVP(k); + } + BOOST_CATCH (boost::archive::archive_exception const& ae){ + exception = ae; + } + BOOST_CATCH_END + BOOST_CHECK( + exception.code == boost::archive::archive_exception::pointer_conflict + ); + } + // if exception wasn't invoked + if(exception.code == boost::archive::archive_exception::no_exception){ + // try to read the archive + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + exception = boost::archive::archive_exception( + boost::archive::archive_exception::no_exception + ); + BOOST_TRY { + ia >> BOOST_SERIALIZATION_NVP(k); + } + BOOST_CATCH (boost::archive::archive_exception const& ae){ + exception = ae; + } + BOOST_CATCH_END + BOOST_CHECK( + exception.code == boost::archive::archive_exception::pointer_conflict + ); + } + std::remove(testfile); + return EXIT_SUCCESS; +} + +int test_main( int /* argc */, char* /* argv */[] ){ + test1(); + test2(); + test3(); + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_delete_pointer.cpp b/src/boost/libs/serialization/test/test_delete_pointer.cpp new file mode 100644 index 00000000..a4b7561f --- /dev/null +++ b/src/boost/libs/serialization/test/test_delete_pointer.cpp @@ -0,0 +1,119 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_delete_pointer.cpp + +// (C) Copyright 2002 Vahan Margaryan. +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) +// + +#include <cstddef> // NULL +#include <fstream> + +#include <cstdio> // remove +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include "test_tools.hpp" +#include <boost/core/no_exceptions_support.hpp> +#include <boost/serialization/throw_exception.hpp> + +#include <boost/serialization/nvp.hpp> +#include <boost/serialization/split_member.hpp> + +//A holds a pointer to another A, but doesn't own the pointer. +//objCount +class A +{ + friend class boost::serialization::access; + template<class Archive> + void save(Archive &ar, const unsigned int /* file_version */) const + { + ar << BOOST_SERIALIZATION_NVP(next_); + } + template<class Archive> + void load(Archive & ar, const unsigned int /* file_version */) + { + ar >> BOOST_SERIALIZATION_NVP(next_); + ++loadcount; + } + BOOST_SERIALIZATION_SPLIT_MEMBER() +public: + A() + { + if(test && objcount == 3) + boost::serialization::throw_exception(boost::archive::archive_exception( + boost::archive::archive_exception::no_exception + )); + next_ = 0; + ++objcount; + } + ~A(){ + delete next_; + --objcount; + } + A* next_; + static int objcount; + static bool test; + static int loadcount; +}; + + +int A::objcount = 0; +int A::loadcount = 0; +bool A::test = false; + +int +test_main( int /* argc */, char* /* argv */[] ) +{ + + //fill the vector with chained A's. The vector is assumed + //to own the objects - we will destroy the objects through this vector. + + A * head = new A; + A* last = head; + unsigned int i; + for(i = 1; i < 9; ++i) + { + A *a = new A; + last->next_ = a; + last = a; + } + + const char * testfile = boost::archive::tmpnam(0); + BOOST_REQUIRE(NULL != testfile); + + //output the list + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << BOOST_SERIALIZATION_NVP(head); + } + + delete head; + BOOST_CHECK(A::objcount == 0); + + head = NULL; + A::test = true; + //read the list back + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + BOOST_TRY { + ia >> BOOST_SERIALIZATION_NVP(head); + } + BOOST_CATCH (...){ + ia.delete_created_pointers(); + } + BOOST_CATCH_END + } + + //identify the leaks + BOOST_CHECK(A::loadcount == 0); + std::remove(testfile); + return EXIT_SUCCESS; +} diff --git a/src/boost/libs/serialization/test/test_deque.cpp b/src/boost/libs/serialization/test/test_deque.cpp new file mode 100644 index 00000000..e144a399 --- /dev/null +++ b/src/boost/libs/serialization/test/test_deque.cpp @@ -0,0 +1,55 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_deque.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <cstddef> +#include <fstream> + +#include <cstdio> // remove +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include <boost/archive/archive_exception.hpp> +#include "test_tools.hpp" + +#include <boost/serialization/deque.hpp> + +#include "A.hpp" +#include "A.ipp" + +int test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + // test array of objects + std::deque<A> adeque, adeque1; + adeque.push_front(A()); + adeque.push_front(A()); + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("adeque",adeque); + } + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("adeque",adeque1); + } + BOOST_CHECK(adeque == adeque1); + + std::remove(testfile); + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_derived.cpp b/src/boost/libs/serialization/test/test_derived.cpp new file mode 100644 index 00000000..4c3697b1 --- /dev/null +++ b/src/boost/libs/serialization/test/test_derived.cpp @@ -0,0 +1,148 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_derived.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <cstddef> // NULL +#include <fstream> + +#include <cstdio> // remove +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include <boost/archive/archive_exception.hpp> +#include "test_tools.hpp" + +#include <boost/serialization/base_object.hpp> +#include <boost/serialization/type_info_implementation.hpp> + +class base +{ + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive & /* ar */, const unsigned int /* file_version */){ + } +public: + virtual ~base(){}; +}; + +class derived1 : public base +{ + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive &ar, const unsigned int /* file_version */){ + ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(base); + } +}; + +class derived2 : public base +{ + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive &ar, const unsigned int /* file_version */){ + ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(base); + } +}; + +// save non-polymorphic classes through a base class pointer +void save_derived(const char *testfile) +{ + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + + // registration not necessary when serializing the most derived pointer + derived1 *d1 = new derived1; + derived2 *d2 = new derived2; + oa << BOOST_SERIALIZATION_NVP(d1) << BOOST_SERIALIZATION_NVP(d2); + + // upcasting non-polymorphic pointers may not lead to the expected + // result. In the current type id system + base *b1 = d1; + base *b2 = d2; + + // Warning, the current type id system does not yield true + // type id for non-polymorphic types + const boost::serialization::extended_type_info & this_type + = boost::serialization::type_info_implementation<base>::type + ::get_const_instance(); + // retrieve the true type of the object pointed to + const boost::serialization::extended_type_info & true_type + = * boost::serialization::type_info_implementation<base>::type + ::get_const_instance().get_derived_extended_type_info(*b1); + + BOOST_WARN_MESSAGE( + !(this_type == true_type), + "current type id system does not support non-polymorphic types" + ); + + oa << BOOST_SERIALIZATION_NVP(b1); + oa << BOOST_SERIALIZATION_NVP(b2); + + delete d1; + delete d2; +} + +// save non-polymorphic classes through a base class pointer +void load_derived(const char *testfile) +{ + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + + // registration not necessary when serializing the most derived pointer + derived1 *d1 = NULL; + derived2 *d2 = NULL; + ia >> BOOST_SERIALIZATION_NVP(d1) >> BOOST_SERIALIZATION_NVP(d2); + + // upcasting non-polymorphic pointers may not lead to the expected + // result. In the current type id system + base *b1 = NULL; + base *b2 = NULL; + + // note: this will produce incorrect results for non-polymorphic classes + ia >> BOOST_SERIALIZATION_NVP(b1); + ia >> BOOST_SERIALIZATION_NVP(b2); + + // Warning, the current type id system does not yield true + // type id for non-polymorphic types + const boost::serialization::extended_type_info & this_type + = boost::serialization::type_info_implementation<base>::type + ::get_const_instance(); + // retrieve the true type of the object pointed to + const boost::serialization::extended_type_info & true_type + = * boost::serialization::type_info_implementation<base>::type + ::get_const_instance().get_derived_extended_type_info(*b1); + + BOOST_WARN_MESSAGE( + ! (this_type == true_type), + "current type id system does fails for non-polymorphic types" + ); + + BOOST_CHECK(b1 == static_cast<base *>(d1)); + BOOST_CHECK(b2 == static_cast<base *>(d2)); + + delete d1; + delete d2; +} + +int +test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + save_derived(testfile); + load_derived(testfile); + std::remove(testfile); + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_derived_class.cpp b/src/boost/libs/serialization/test/test_derived_class.cpp new file mode 100644 index 00000000..f123c92c --- /dev/null +++ b/src/boost/libs/serialization/test/test_derived_class.cpp @@ -0,0 +1,49 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_derived_class.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <fstream> + +#include <cstdio> // remove +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include "test_tools.hpp" + +#include "B.hpp" +#include "A.ipp" + +int test_main( int /*argc*/, char* /*argv*/[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + + BOOST_REQUIRE(NULL != testfile); + + B b, b1; + + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("b", b); + } + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("b1", b1); + } + BOOST_CHECK(b == b1); + std::remove(testfile); + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_derived_class_ptr.cpp b/src/boost/libs/serialization/test/test_derived_class_ptr.cpp new file mode 100644 index 00000000..d6385cfd --- /dev/null +++ b/src/boost/libs/serialization/test/test_derived_class_ptr.cpp @@ -0,0 +1,52 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_deriviec_class_.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <cstddef> // NULL +#include <fstream> + +#include <cstdio> // remove +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include "test_tools.hpp" + +#include "B.hpp" +#include "A.ipp" + +int test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + B * tb = new B; + B * tb1 = NULL; + + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("tb", tb); + } + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("tb",tb1); + } + BOOST_CHECK(tb != tb1); + BOOST_CHECK(*tb == *tb1); + delete tb; + std::remove(testfile); + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_diamond.cpp b/src/boost/libs/serialization/test/test_diamond.cpp new file mode 100644 index 00000000..d62e5673 --- /dev/null +++ b/src/boost/libs/serialization/test/test_diamond.cpp @@ -0,0 +1,205 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_diamond.cpp + +// (C) Copyright 2002-2009 Vladimir Prus and Robert Ramey. +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// test of serialization library for diamond inheritence situations + +#include <cstddef> // NULL +#include <fstream> +#include <iostream> + +#include <boost/config.hpp> +#include <cstdio> // remove +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include "test_tools.hpp" + +#include <boost/serialization/map.hpp> +#include <boost/serialization/utility.hpp> +#include <boost/serialization/split_member.hpp> +#include <boost/serialization/tracking.hpp> +#include <boost/serialization/base_object.hpp> +#include <boost/serialization/nvp.hpp> +#include <boost/serialization/export.hpp> + +int save_count = 0; // used to detect when base class is saved multiple times +int load_count = 0; // used to detect when base class is loaded multiple times + +class base { +public: + base() : i(0) {} + base(int i) : i(i) + { + m[i] = "text"; + } + + template<class Archive> + void save(Archive &ar, const unsigned int /* file_version */) const + { + std::cout << "Saving base\n"; + ar << BOOST_SERIALIZATION_NVP(i); + ar << BOOST_SERIALIZATION_NVP(m); + ++save_count; + } + + template<class Archive> + void load(Archive & ar, const unsigned int /* file_version */) + { + std::cout << "Restoring base\n"; + ar >> BOOST_SERIALIZATION_NVP(i); + ar >> BOOST_SERIALIZATION_NVP(m); + ++load_count; + } + + BOOST_SERIALIZATION_SPLIT_MEMBER() + + bool operator==(const base& another) const + { + return i == another.i && m == another.m; + } + // make polymorphic by marking at least one function virtual + virtual ~base() {}; +private: + int i; + std::map<int, std::string> m; +}; + +// note: the default is for object tracking to be performed if and only +// if and object of the corresponding class is anywhere serialized +// through a pointer. In this example, that doesn't occur so +// by default, the shared base object wouldn't normally be tracked. +// This would leave to multiple save/load operation of the data in +// this shared base class. This wouldn't cause an error, but it would +// be a waste of time. So set the tracking behavior trait of the base +// class to always track serialized objects of that class. This permits +// the system to detect and elminate redundent save/load operations. +// (It is concievable that this might someday be detected automatically +// but for now, this is not done so we have to rely on the programmer +// to specify this trait) +BOOST_CLASS_TRACKING(base, track_always) + +class derived1 : virtual public base { +public: + template<class Archive> + void save(Archive &ar, const unsigned int /* file_version */) const + { + std::cout << "Saving derived1\n"; + ar << BOOST_SERIALIZATION_BASE_OBJECT_NVP(base); + } + + template<class Archive> + void load(Archive & ar, const unsigned int /* file_version */) + { + std::cout << "Restoring derived1\n"; + ar >> BOOST_SERIALIZATION_BASE_OBJECT_NVP(base); + } + + BOOST_SERIALIZATION_SPLIT_MEMBER() +}; + +class derived2 : virtual public base { +public: + template<class Archive> + void save(Archive &ar, const unsigned int /* file_version */) const + { + std::cout << "Saving derived2\n"; + ar << BOOST_SERIALIZATION_BASE_OBJECT_NVP(base); + } + + template<class Archive> + void load(Archive & ar, const unsigned int /* file_version */) + { + std::cout << "Restoring derived2\n"; + ar >> BOOST_SERIALIZATION_BASE_OBJECT_NVP(base); + } + + BOOST_SERIALIZATION_SPLIT_MEMBER() +}; + +class final : public derived1, public derived2 { +public: + final() {} + final(int i) : base(i) {} + + template<class Archive> + void save(Archive &ar, const unsigned int /* file_version */) const + { + std::cout << "Saving final\n"; + ar << BOOST_SERIALIZATION_BASE_OBJECT_NVP(derived1); + ar << BOOST_SERIALIZATION_BASE_OBJECT_NVP(derived2); + } + + template<class Archive> + void load(Archive & ar, const unsigned int /* file_version */) + { + std::cout << "Restoring final\n"; + ar >> BOOST_SERIALIZATION_BASE_OBJECT_NVP(derived1); + ar >> BOOST_SERIALIZATION_BASE_OBJECT_NVP(derived2); + } + + BOOST_SERIALIZATION_SPLIT_MEMBER() +}; + +BOOST_CLASS_EXPORT(final) + +int +test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + const final b(3); + { + test_ostream ofs(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(ofs); + oa << boost::serialization::make_nvp("b", b); + } + + final b2; + { + test_istream ifs(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(ifs); + ia >> boost::serialization::make_nvp("b2", b2); + } + BOOST_CHECK(1 == save_count); + BOOST_CHECK(1 == load_count); + BOOST_CHECK(b2 == b); + std::remove(testfile); + + // do the same test with pointers + testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + save_count = 0; + load_count = 0; + + const base* bp = new final( 3 ); + { + test_ostream ofs(testfile); + test_oarchive oa(ofs); + oa << BOOST_SERIALIZATION_NVP(bp); + } + + base* bp2; + { + test_istream ifs(testfile); + test_iarchive ia(ifs); + ia >> BOOST_SERIALIZATION_NVP(bp2); + } + + BOOST_CHECK(1 == save_count); + BOOST_CHECK(1 == load_count); + BOOST_CHECK(*bp2 == *bp); + delete bp; + std::remove(testfile); + + return EXIT_SUCCESS; +} diff --git a/src/boost/libs/serialization/test/test_diamond_complex.cpp b/src/boost/libs/serialization/test/test_diamond_complex.cpp new file mode 100644 index 00000000..388eccf2 --- /dev/null +++ b/src/boost/libs/serialization/test/test_diamond_complex.cpp @@ -0,0 +1,480 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_diamond.cpp + +// (C) Copyright 2002-2009 Vladimir Prus, Robert Ramey and Takatoshi Kondo. +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// test of serialization library for diamond inheritence situations + +#include <cstddef> // NULL +#include <fstream> +#include <iostream> + +#include <boost/config.hpp> +#include <cstdio> // remove +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include "test_tools.hpp" + +#include <boost/serialization/map.hpp> +#include <boost/serialization/utility.hpp> +#include <boost/serialization/split_member.hpp> +#include <boost/serialization/tracking.hpp> +#include <boost/serialization/base_object.hpp> +#include <boost/serialization/nvp.hpp> +#include <boost/serialization/export.hpp> + +int save_count = 0; // used to detect when EXnLevel1 class is saved multiple times +int load_count = 0; // used to detect when EXnLevel1 class is loaded multiple times + +// inheritance structure +// +// EX1Level1<-+-EX1Level2_A<-+-+-EX1Level3_A +// | | | +// +-EX1Level2_B<-+ +-EX1Level3_B<--EX1Level4 +// +// EXPORT Sequence EX1Level3_A, EX1Level4 +//--------------------------------------------------------- +// EX2Level1<-+-EX2Level2_A<-+-+-EX2Level3_A +// | | | +// +-EX2Level2_B<-+ +-EX2Level3_B<--EX2Level4 +// +// EXPORT Sequence EX2Level4, EX2Level3_A + +class EX1Level1 { +public: + EX1Level1() : i(0) {} + EX1Level1(int i) : i(i) + { + m[i] = "text"; + } + + template<class Archive> + void save(Archive &ar, const unsigned int /* file_version */) const + { + std::cout << "Saving EX1Level1\n"; + ar << BOOST_SERIALIZATION_NVP(i); + ar << BOOST_SERIALIZATION_NVP(m); + ++save_count; + } + + template<class Archive> + void load(Archive & ar, const unsigned int /* file_version */) + { + std::cout << "Restoring EX1Level1\n"; + ar >> BOOST_SERIALIZATION_NVP(i); + ar >> BOOST_SERIALIZATION_NVP(m); + ++load_count; + } + + BOOST_SERIALIZATION_SPLIT_MEMBER() + + bool operator==(const EX1Level1& another) const + { + return i == another.i && m == another.m; + } + // make polymorphic by marking at least one function virtual + virtual ~EX1Level1() {}; +private: + int i; + std::map<int, std::string> m; +}; + +// note: the default is for object tracking to be performed if and only +// if and object of the corresponding class is anywhere serialized +// through a pointer. In this example, that doesn't occur so +// by default, the shared EX1Level1 object wouldn't normally be tracked. +// This would leave to multiple save/load operation of the data in +// this shared EX1Level1 class. This wouldn't cause an error, but it would +// be a waste of time. So set the tracking behavior trait of the EX1Level1 +// class to always track serialized objects of that class. This permits +// the system to detect and elminate redundent save/load operations. +// (It is concievable that this might someday be detected automatically +// but for now, this is not done so we have to rely on the programmer +// to specify this trait) +BOOST_CLASS_TRACKING(EX1Level1, track_always) + +class EX1Level2_A : virtual public EX1Level1 { +public: + template<class Archive> + void save(Archive &ar, const unsigned int /* file_version */) const + { + std::cout << "Saving EX1Level2_A\n"; + ar << BOOST_SERIALIZATION_BASE_OBJECT_NVP(EX1Level1); + } + + template<class Archive> + void load(Archive & ar, const unsigned int /* file_version */) + { + std::cout << "Restoring EX1Level2_A\n"; + ar >> BOOST_SERIALIZATION_BASE_OBJECT_NVP(EX1Level1); + } + + BOOST_SERIALIZATION_SPLIT_MEMBER() +}; + +class EX1Level2_B : virtual public EX1Level1 { +public: + template<class Archive> + void save(Archive &ar, const unsigned int /* file_version */) const + { + std::cout << "Saving EX1Level2_B\n"; + ar << BOOST_SERIALIZATION_BASE_OBJECT_NVP(EX1Level1); + } + + template<class Archive> + void load(Archive & ar, const unsigned int /* file_version */) + { + std::cout << "Restoring EX1Level2_B\n"; + ar >> BOOST_SERIALIZATION_BASE_OBJECT_NVP(EX1Level1); + } + + BOOST_SERIALIZATION_SPLIT_MEMBER() +}; + +class EX1Level3_A : public EX1Level2_A, public EX1Level2_B { +public: + EX1Level3_A() {} + EX1Level3_A(int i) : EX1Level1(i) {} + + template<class Archive> + void save(Archive &ar, const unsigned int /* file_version */) const + { + std::cout << "Saving EX1Level3_A\n"; + ar << BOOST_SERIALIZATION_BASE_OBJECT_NVP(EX1Level2_A); + ar << BOOST_SERIALIZATION_BASE_OBJECT_NVP(EX1Level2_B); + } + + template<class Archive> + void load(Archive & ar, const unsigned int /* file_version */) + { + std::cout << "Restoring EX1Level3_A\n"; + ar >> BOOST_SERIALIZATION_BASE_OBJECT_NVP(EX1Level2_A); + ar >> BOOST_SERIALIZATION_BASE_OBJECT_NVP(EX1Level2_B); + } + + BOOST_SERIALIZATION_SPLIT_MEMBER() +}; + + +class EX1Level3_B : public EX1Level2_A, public EX1Level2_B { +public: + EX1Level3_B() {} + EX1Level3_B(int) {} + + template<class Archive> + void save(Archive &ar, const unsigned int /* file_version */) const + { + std::cout << "Saving EX1Level3_B\n"; + ar << BOOST_SERIALIZATION_BASE_OBJECT_NVP(EX1Level2_A); + ar << BOOST_SERIALIZATION_BASE_OBJECT_NVP(EX1Level2_B); + } + + template<class Archive> + void load(Archive & ar, const unsigned int /* file_version */) + { + std::cout << "Restoring EX1Level3_B\n"; + ar >> BOOST_SERIALIZATION_BASE_OBJECT_NVP(EX1Level2_A); + ar >> BOOST_SERIALIZATION_BASE_OBJECT_NVP(EX1Level2_B); + } + + BOOST_SERIALIZATION_SPLIT_MEMBER() +}; + +class EX1Level4 : public EX1Level3_B { +public: + EX1Level4() {} + EX1Level4(int i) : EX1Level1(i) {} + + template<class Archive> + void save(Archive &ar, const unsigned int /* file_version */) const + { + std::cout << "Saving EX1Level4\n"; + ar << BOOST_SERIALIZATION_BASE_OBJECT_NVP(EX1Level3_B); + } + + template<class Archive> + void load(Archive & ar, const unsigned int /* file_version */) + { + std::cout << "Restoring EX1Level4\n"; + ar >> BOOST_SERIALIZATION_BASE_OBJECT_NVP(EX1Level3_B); + } + + BOOST_SERIALIZATION_SPLIT_MEMBER() +}; + + +class EX2Level1 { +public: + EX2Level1() : i(0) {} + EX2Level1(int i) : i(i) + { + m[i] = "text"; + } + + template<class Archive> + void save(Archive &ar, const unsigned int /* file_version */) const + { + std::cout << "Saving EX2Level1\n"; + ar << BOOST_SERIALIZATION_NVP(i); + ar << BOOST_SERIALIZATION_NVP(m); + ++save_count; + } + + template<class Archive> + void load(Archive & ar, const unsigned int /* file_version */) + { + std::cout << "Restoring EX2Level1\n"; + ar >> BOOST_SERIALIZATION_NVP(i); + ar >> BOOST_SERIALIZATION_NVP(m); + ++load_count; + } + + BOOST_SERIALIZATION_SPLIT_MEMBER() + + bool operator==(const EX2Level1& another) const + { + return i == another.i && m == another.m; + } + // make polymorphic by marking at least one function virtual + virtual ~EX2Level1() {}; +private: + int i; + std::map<int, std::string> m; +}; + +// note: the default is for object tracking to be performed if and only +// if and object of the corresponding class is anywhere serialized +// through a pointer. In this example, that doesn't occur so +// by default, the shared EX2Level1 object wouldn't normally be tracked. +// This would leave to multiple save/load operation of the data in +// this shared EX2Level1 class. This wouldn't cause an error, but it would +// be a waste of time. So set the tracking behavior trait of the EX2Level1 +// class to always track serialized objects of that class. This permits +// the system to detect and elminate redundent save/load operations. +// (It is concievable that this might someday be detected automatically +// but for now, this is not done so we have to rely on the programmer +// to specify this trait) +BOOST_CLASS_TRACKING(EX2Level1, track_always) + +class EX2Level2_A : virtual public EX2Level1 { +public: + template<class Archive> + void save(Archive &ar, const unsigned int /* file_version */) const + { + std::cout << "Saving EX2Level2_A\n"; + ar << BOOST_SERIALIZATION_BASE_OBJECT_NVP(EX2Level1); + } + + template<class Archive> + void load(Archive & ar, const unsigned int /* file_version */) + { + std::cout << "Restoring EX2Level2_A\n"; + ar >> BOOST_SERIALIZATION_BASE_OBJECT_NVP(EX2Level1); + } + + BOOST_SERIALIZATION_SPLIT_MEMBER() +}; + +class EX2Level2_B : virtual public EX2Level1 { +public: + template<class Archive> + void save(Archive &ar, const unsigned int /* file_version */) const + { + std::cout << "Saving EX2Level2_B\n"; + ar << BOOST_SERIALIZATION_BASE_OBJECT_NVP(EX2Level1); + } + + template<class Archive> + void load(Archive & ar, const unsigned int /* file_version */) + { + std::cout << "Restoring EX2Level2_B\n"; + ar >> BOOST_SERIALIZATION_BASE_OBJECT_NVP(EX2Level1); + } + + BOOST_SERIALIZATION_SPLIT_MEMBER() +}; + +class EX2Level3_A : public EX2Level2_A, public EX2Level2_B { +public: + EX2Level3_A() {} + EX2Level3_A(int i) : EX2Level1(i) {} + + template<class Archive> + void save(Archive &ar, const unsigned int /* file_version */) const + { + std::cout << "Saving EX2Level3_A\n"; + ar << BOOST_SERIALIZATION_BASE_OBJECT_NVP(EX2Level2_A); + ar << BOOST_SERIALIZATION_BASE_OBJECT_NVP(EX2Level2_B); + } + + template<class Archive> + void load(Archive & ar, const unsigned int /* file_version */) + { + std::cout << "Restoring EX2Level3_A\n"; + ar >> BOOST_SERIALIZATION_BASE_OBJECT_NVP(EX2Level2_A); + ar >> BOOST_SERIALIZATION_BASE_OBJECT_NVP(EX2Level2_B); + } + + BOOST_SERIALIZATION_SPLIT_MEMBER() +}; + + +class EX2Level3_B : public EX2Level2_A, public EX2Level2_B { +public: + EX2Level3_B() {} + EX2Level3_B(int i) : EX2Level1(i) {} + + template<class Archive> + void save(Archive &ar, const unsigned int /* file_version */) const + { + std::cout << "Saving EX2Level3_B\n"; + ar << BOOST_SERIALIZATION_BASE_OBJECT_NVP(EX2Level2_A); + ar << BOOST_SERIALIZATION_BASE_OBJECT_NVP(EX2Level2_B); + } + + template<class Archive> + void load(Archive & ar, const unsigned int /* file_version */) + { + std::cout << "Restoring EX2Level3_B\n"; + ar >> BOOST_SERIALIZATION_BASE_OBJECT_NVP(EX2Level2_A); + ar >> BOOST_SERIALIZATION_BASE_OBJECT_NVP(EX2Level2_B); + } + + BOOST_SERIALIZATION_SPLIT_MEMBER() +}; + +class EX2Level4 : public EX2Level3_B { +public: + EX2Level4() {} + EX2Level4(int i) : EX2Level1(i) {} + + template<class Archive> + void save(Archive &ar, const unsigned int /* file_version */) const + { + std::cout << "Saving EX2Level4\n"; + ar << BOOST_SERIALIZATION_BASE_OBJECT_NVP(EX2Level3_B); + } + + template<class Archive> + void load(Archive & ar, const unsigned int /* file_version */) + { + std::cout << "Restoring EX2Level4\n"; + ar >> BOOST_SERIALIZATION_BASE_OBJECT_NVP(EX2Level3_B); + } + + BOOST_SERIALIZATION_SPLIT_MEMBER() +}; + +BOOST_CLASS_EXPORT(EX1Level4) +BOOST_CLASS_EXPORT(EX1Level3_A) + +BOOST_CLASS_EXPORT(EX2Level3_A) +BOOST_CLASS_EXPORT(EX2Level4) + +int +test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + { + save_count = 0; + load_count = 0; + + const EX1Level3_A ex1L3a_save(3); + const EX1Level1 *ex1L1_save = &ex1L3a_save; + { + test_ostream ofs(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(ofs); + oa << boost::serialization::make_nvp("ex1L1_save", ex1L1_save); + } + + EX1Level1 *ex1L1_load; + { + test_istream ifs(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(ifs); + ia >> boost::serialization::make_nvp("ex1L1_load", ex1L1_load); + } + BOOST_CHECK(1 == save_count); + BOOST_CHECK(1 == load_count); + BOOST_CHECK(*ex1L1_save == *ex1L1_load); + std::remove(testfile); + } + { + save_count = 0; + load_count = 0; + + const EX1Level4 ex1L4_save(3); + const EX1Level1 *ex1L1_save = &ex1L4_save; + { + test_ostream ofs(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(ofs); + oa << boost::serialization::make_nvp("ex1L1_save", ex1L1_save); + } + + EX1Level1 *ex1L1_load; + { + test_istream ifs(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(ifs); + ia >> boost::serialization::make_nvp("ex1L1_load", ex1L1_load); + } + BOOST_CHECK(1 == save_count); + BOOST_CHECK(1 == load_count); + BOOST_CHECK(*ex1L1_save == *ex1L1_load); + std::remove(testfile); + } + { + save_count = 0; + load_count = 0; + + const EX2Level3_A ex2L3a_save(3); + const EX2Level1 *ex2L1_save = &ex2L3a_save; + { + test_ostream ofs(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(ofs); + oa << boost::serialization::make_nvp("ex2L1_save", ex2L1_save); + } + + EX2Level1 *ex2L1_load; + { + test_istream ifs(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(ifs); + ia >> boost::serialization::make_nvp("ex2L1_load", ex2L1_load); + } + BOOST_CHECK(1 == save_count); + BOOST_CHECK(1 == load_count); + BOOST_CHECK(*ex2L1_save == *ex2L1_load); + std::remove(testfile); + } + { + save_count = 0; + load_count = 0; + + const EX2Level4 ex2L4_save(3); + const EX2Level1 *ex2L1_save = &ex2L4_save; + { + test_ostream ofs(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(ofs); + oa << boost::serialization::make_nvp("ex2L1_save", ex2L1_save); + } + + EX2Level1 *ex2L1_load; + { + test_istream ifs(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(ifs); + ia >> boost::serialization::make_nvp("ex2L1_load", ex2L1_load); + } + BOOST_CHECK(1 == save_count); + BOOST_CHECK(1 == load_count); + BOOST_CHECK(*ex2L1_save == *ex2L1_load); + std::remove(testfile); + } + return EXIT_SUCCESS; +} diff --git a/src/boost/libs/serialization/test/test_dll_exported.cpp b/src/boost/libs/serialization/test/test_dll_exported.cpp new file mode 100644 index 00000000..92adbc25 --- /dev/null +++ b/src/boost/libs/serialization/test/test_dll_exported.cpp @@ -0,0 +1,137 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_dll_exported.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +// This is an overly complex test. The purpose of this test is to +// demostrate and test the ability to serialize a hiarchy of class +// through a base class pointer even though those class might be +// implemente in different dlls and use different extended type info +// systems. +// +// polymorphic_ base is locally declared and defined. It use the +// "no_rtti" extended type info system. + +// polymorphic_derived1 is locally declared and defined. It uses +// the default "type_id" extended type info system + +// polymorphic_derived2 is declared in polymorphic_derived.hpp +// and defined in dll_polymorphic_derived2. It uses the typeid +// system. + +#include <cstddef> // NULL +#include <fstream> + +#include <cstdio> // remove +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include <boost/archive/polymorphic_oarchive.hpp> +#include <boost/archive/polymorphic_iarchive.hpp> + +#include "test_tools.hpp" + +#include <boost/archive/polymorphic_oarchive.hpp> +#include <boost/archive/polymorphic_iarchive.hpp> + +#include <boost/serialization/base_object.hpp> +#include <boost/serialization/export.hpp> +#include <boost/serialization/access.hpp> + +#define POLYMORPHIC_BASE_IMPORT +#include "polymorphic_base.hpp" + +#include "polymorphic_derived1.hpp" + +#define POLYMORPHIC_DERIVED2_IMPORT +#include "polymorphic_derived2.hpp" + +// save exported polymorphic class +void save_exported(const char *testfile) +{ + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa_implementation(os, TEST_ARCHIVE_FLAGS); + boost::archive::polymorphic_oarchive & oa_interface = oa_implementation; + + polymorphic_base *rb1 = new polymorphic_derived1; + polymorphic_base *rb2 = new polymorphic_derived2; + polymorphic_derived2 *rd21 = new polymorphic_derived2; + + // export will permit correct serialization + // through a pointer to a base class + oa_interface << BOOST_SERIALIZATION_NVP(rb1); + oa_interface << BOOST_SERIALIZATION_NVP(rb2); + oa_interface << BOOST_SERIALIZATION_NVP(rd21); + + delete rd21; + delete rb2; + delete rb1; +} + +// save exported polymorphic class +void load_exported(const char *testfile) +{ + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia_implementation(is, TEST_ARCHIVE_FLAGS); + boost::archive::polymorphic_iarchive & ia_interface = ia_implementation; + + polymorphic_base *rb1 = NULL; + polymorphic_base *rb2 = NULL; + polymorphic_derived2 *rd21 = NULL; + + // export will permit correct serialization + // through a pointer to a base class + ia_interface >> BOOST_SERIALIZATION_NVP(rb1); + BOOST_CHECK_MESSAGE( + boost::serialization::type_info_implementation<polymorphic_derived1> + ::type::get_const_instance() + == + * boost::serialization::type_info_implementation<polymorphic_base> + ::type::get_const_instance().get_derived_extended_type_info(*rb1), + "restored pointer b1 not of correct type" + ); + ia_interface >> BOOST_SERIALIZATION_NVP(rb2); + BOOST_CHECK_MESSAGE( + boost::serialization::type_info_implementation<polymorphic_derived2> + ::type::get_const_instance() + == + * boost::serialization::type_info_implementation<polymorphic_base> + ::type::get_const_instance().get_derived_extended_type_info(*rb2), + "restored pointer b2 not of correct type" + ); + ia_interface >> BOOST_SERIALIZATION_NVP(rd21); + BOOST_CHECK_MESSAGE( + boost::serialization::type_info_implementation<polymorphic_derived2> + ::type::get_const_instance() + == + * boost::serialization::type_info_implementation<polymorphic_derived2> + ::type::get_const_instance().get_derived_extended_type_info(*rd21), + "restored pointer d2 not of correct type" + ); + delete rd21; + delete rb2; + delete rb1; +} + +int +test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + save_exported(testfile); + load_exported(testfile); + std::remove(testfile); + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_dll_plugin.cpp b/src/boost/libs/serialization/test/test_dll_plugin.cpp new file mode 100644 index 00000000..fe095231 --- /dev/null +++ b/src/boost/libs/serialization/test/test_dll_plugin.cpp @@ -0,0 +1,211 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_dll_plugin.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +// Note this test creates, serializes, and destroys +// a class instance while knowing nothing more than its +// exported class ID (GUID) and a base class from which +// it is derived. This is referred to as a "plugin" +// since the same program could, without recompilation, +// manipulate any number of derived types - even those +// which have not been yet been created. + +#include <fstream> + +#include <cstdio> // remove +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include <boost/archive/archive_exception.hpp> + +// for now, only test with simple text and polymorphic archive +#include "test_tools.hpp" + +#include <boost/serialization/base_object.hpp> +#include <boost/serialization/export.hpp> +#include <boost/serialization/type_info_implementation.hpp> +#include <boost/serialization/access.hpp> +#include <boost/serialization/void_cast.hpp> +#include <boost/serialization/extended_type_info.hpp> + +#include "polymorphic_base.hpp" + +// declare and implement a derived class in our own executable +class polymorphic_derived1 : public polymorphic_base +{ + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive &ar, const unsigned int /* file_version */){ + ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(polymorphic_base); + } + const char * get_key() const{ + return + boost::serialization::type_info_implementation< + polymorphic_derived1 + >::type::get_const_instance().get_key(); + } +public: + virtual ~polymorphic_derived1(){} +}; + +// This class is derived from polymorphic_base which uses the no_rtti system +// rather than the typeid system. This system uses the exported name as the +// type identifier key. This MUST be exported!!! +BOOST_CLASS_EXPORT(polymorphic_derived1) + +// MWerks users can do this to make their code work +BOOST_SERIALIZATION_MWERKS_BASE_AND_DERIVED(polymorphic_base, polymorphic_derived1) + +// save exported polymorphic class +void save_exported(const char *testfile) +{ + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + + polymorphic_base *rb1 = new polymorphic_derived1; + + // get the eti record for the exported type "polymorphic_derived2" + boost::serialization::extended_type_info const * const d2_eti = + boost::serialization::extended_type_info::find( + "polymorphic_derived2" + ); + assert(NULL != d2_eti); + + // create a new instance of the type referred to by this record. + // in this example, we happen to know that the class constructor + // takes no arguments. + void const * const rd2 = d2_eti->construct(); + assert(NULL != rd2); + + // transform the pointer to a pointer to the base class + polymorphic_base const * const rb2 + = static_cast<polymorphic_base const *>( + boost::serialization::void_upcast( + * d2_eti, + boost::serialization::type_info_implementation<polymorphic_base> + ::type::get_const_instance(), + rd2 + ) + ); + + // export will permit correct serialization + // through a pointer to a base class + oa << BOOST_SERIALIZATION_NVP(rb1); + oa << BOOST_SERIALIZATION_NVP(rb2); + + // don't need these any more - don't leak memory + delete rb1; + // note delete original handle - not runtime cast one !!! + //delete rb2; + d2_eti->destroy(rd2); +} + +// save exported polymorphic class +void load_exported(const char *testfile) +{ + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + + polymorphic_base *rb1 = NULL; + polymorphic_base *rb2 = NULL; + + // export will permit correct serialization + // through a pointer to a base class + ia >> BOOST_SERIALIZATION_NVP(rb1); + + BOOST_CHECK_MESSAGE( + boost::serialization::type_info_implementation<polymorphic_derived1> + ::type::get_const_instance() + == + * boost::serialization::type_info_implementation<polymorphic_base> + ::type::get_const_instance().get_derived_extended_type_info(*rb1), + "restored pointer b1 not of correct type" + ); + ia >> BOOST_SERIALIZATION_NVP(rb2); + + // get the eti record for the exported type "polymorphic_derived2" + boost::serialization::extended_type_info const * const d2_eti = + boost::serialization::extended_type_info::find( + "polymorphic_derived2" + ); + assert(NULL != d2_eti); + + BOOST_CHECK_MESSAGE( + * d2_eti + == + * boost::serialization::type_info_implementation<polymorphic_base> + ::type::get_const_instance().get_derived_extended_type_info(*rb2), + "restored pointer b2 not of correct type" + ); + + delete rb1; + delete rb2; +} + +#ifdef BOOST_WINDOWS + +#define WIN32_LEAN_AND_MEAN +#include <TCHAR.H> +#include <windows.h> + +int +test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + HINSTANCE hDLL; // Handle to DLL + hDLL = LoadLibrary(_T("polymorphic_derived2.dll")); + BOOST_CHECK_MESSAGE( + (0 != hDLL), + "Failed to find/load polymorphic_derived2" + ); + if(0 == hDLL) + return EXIT_FAILURE; + + save_exported(testfile); + load_exported(testfile); + FreeLibrary(hDLL); + + std::remove(testfile); + return EXIT_SUCCESS; +} + +#else // presume *nix + +#include <dlfcn.h> + +int +test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + void * hDLL; // Handle to DLL + hDLL = dlopen("polymorphic_derived2.so", RTLD_NOW | RTLD_GLOBAL); + BOOST_CHECK_MESSAGE((0 != hDLL), "Failed to find/load plugin_polymorphic_derived2" ); + BOOST_CHECK_MESSAGE((0 != hDLL), dlerror() ); + if(0 == hDLL) + return EXIT_FAILURE; + + save_exported(testfile); + load_exported(testfile); + dlclose(hDLL); + + std::remove(testfile); + return EXIT_SUCCESS; +} + +#endif + +// EOF diff --git a/src/boost/libs/serialization/test/test_dll_simple.cpp b/src/boost/libs/serialization/test/test_dll_simple.cpp new file mode 100644 index 00000000..dd7f98bc --- /dev/null +++ b/src/boost/libs/serialization/test/test_dll_simple.cpp @@ -0,0 +1,247 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_dll_simple.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +// invoke header for a custom archive test. + +#include <cstddef> // NULL +#include <fstream> + +#include <cstdio> // remove +#include <boost/config.hpp> + +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +// for now, only test with simple text and polymorphic archive +#include "test_tools.hpp" +#include "text_archive.hpp" + +#include <boost/archive/polymorphic_text_oarchive.hpp> +#include <boost/archive/polymorphic_text_iarchive.hpp> + +#define A_IMPORT +#include "A.hpp" + +// simple class with text archive compiled in dll +void +test1(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + const A a; + A a1; + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + boost::archive::text_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("a", a); + } + { + test_istream is(testfile, TEST_STREAM_FLAGS); + boost::archive::text_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("a", a1); + } + BOOST_CHECK_EQUAL(a, a1); + + std::remove(testfile); +} + +// simple class with polymorphic archive compiled in dll +void +test2(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + const A a; + A a1; + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + boost::archive::polymorphic_text_oarchive oa(os, TEST_ARCHIVE_FLAGS); + boost::archive::polymorphic_oarchive & poa(oa); + poa << boost::serialization::make_nvp("a", a); + } + { + test_istream is(testfile, TEST_STREAM_FLAGS); + boost::archive::polymorphic_text_iarchive ia(is, TEST_ARCHIVE_FLAGS); + boost::archive::polymorphic_iarchive & pia(ia); + pia >> boost::serialization::make_nvp("a", a1); + } + BOOST_CHECK_EQUAL(a, a1); + + std::remove(testfile); +} + +// simple class pointer with text archive compiled in dll +void +test3(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + const A *a = new A; + A *a1; + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + boost::archive::text_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("a", a); + } + { + test_istream is(testfile, TEST_STREAM_FLAGS); + boost::archive::text_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("a", a1); + } + BOOST_CHECK_EQUAL(*a, *a1); + + std::remove(testfile); + delete a; +} + +// simple class pointer with polymorphic archive compiled in dll +void +test4(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + const A *a = new A; + A *a1; + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + boost::archive::polymorphic_text_oarchive oa(os, TEST_ARCHIVE_FLAGS); + boost::archive::polymorphic_oarchive & poa(oa); + poa << boost::serialization::make_nvp("a", a); + } + { + test_istream is(testfile, TEST_STREAM_FLAGS); + boost::archive::polymorphic_text_iarchive ia(is, TEST_ARCHIVE_FLAGS); + boost::archive::polymorphic_iarchive & pia(ia); + pia >> boost::serialization::make_nvp("a", a1); + } + BOOST_CHECK_EQUAL(*a, *a1); + + std::remove(testfile); + delete a; +} + +#include "B.hpp" + +// derived class with base text archive compiled in dll +void +test5(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + const B b; + B b1; + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + boost::archive::text_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("b", b); + } + { + test_istream is(testfile, TEST_STREAM_FLAGS); + boost::archive::text_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("b", b1); + } + BOOST_CHECK_EQUAL(b, b1); + + std::remove(testfile); +} + +// derived class with base base compiled with polymorphic archive in dll +void +test6(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + const B b; + B b1; + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + boost::archive::polymorphic_text_oarchive oa(os, TEST_ARCHIVE_FLAGS); + boost::archive::polymorphic_oarchive & poa(oa); + poa << boost::serialization::make_nvp("b", b); + } + { + test_istream is(testfile, TEST_STREAM_FLAGS); + boost::archive::polymorphic_text_iarchive ia(is, TEST_ARCHIVE_FLAGS); + boost::archive::polymorphic_iarchive & pia(ia); + pia >> boost::serialization::make_nvp("b", b1); + } + BOOST_CHECK_EQUAL(b, b1); + + std::remove(testfile); +} + +// derived class pointer with base text archive compiled in dll +void +test7(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + const B *b = new B; + B *b1; + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + boost::archive::text_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("b", b); + } + { + test_istream is(testfile, TEST_STREAM_FLAGS); + boost::archive::text_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("b", b1); + } + BOOST_CHECK_EQUAL(*b, *b1); + + std::remove(testfile); + delete b; +} + +// derived class pointer with base polymorphic archive compiled in dll +void +test8(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + const B *b = new B; + B *b1; + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + boost::archive::polymorphic_text_oarchive oa(os, TEST_ARCHIVE_FLAGS); + boost::archive::polymorphic_oarchive & poa(oa); + poa << boost::serialization::make_nvp("b", b); + } + { + test_istream is(testfile, TEST_STREAM_FLAGS); + boost::archive::polymorphic_text_iarchive ia(is, TEST_ARCHIVE_FLAGS); + boost::archive::polymorphic_iarchive & pia(ia); + pia >> boost::serialization::make_nvp("b", b1); + } + BOOST_CHECK_EQUAL(*b, *b1); + + std::remove(testfile); + delete b; +} + + +int +test_main( int /* argc */, char* /* argv */[] ) +{ + test1(); + test2(); + test3(); + test4(); + test5(); + test6(); + test7(); + test8(); + return EXIT_SUCCESS; +} + diff --git a/src/boost/libs/serialization/test/test_enable_shared_from_this.cpp b/src/boost/libs/serialization/test/test_enable_shared_from_this.cpp new file mode 100644 index 00000000..9003aee1 --- /dev/null +++ b/src/boost/libs/serialization/test/test_enable_shared_from_this.cpp @@ -0,0 +1,195 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_enable_shared_from_this.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// This demonstrates a problem with boost::serialization and boost::enable_shared_from_this. +// (boost version 1.53) +// See boost TRAC ticket #9567 +// +// Given the following class structure: +// Base is a simple class +// Derived inherits from Base +// Derived also inherits from boost::enable_shared_from_this<Derived> +// Base and Derived implement boost::serialization +// +// When deserializing an instance of Derived into a vector of boost::shared_ptr<Derived>: +// Base and Derived members are reconstructed correctly. +// Derived::shared_from_this() works as expected. +// +// But when deserializing an instance of Derived into a vector of boost::shared_ptr<Base>: +// Base and Derived members are still reconstructed correctly. +// Derived::shared_from_this() throws a bad_weak_ptr exception. +// This is because enable_shared_from_this::weak_ptr is NOT reconstructed - It is zero. + +#include <sstream> + +#include <boost/archive/text_oarchive.hpp> +#include <boost/archive/text_iarchive.hpp> + +#include <boost/enable_shared_from_this.hpp> +#include <boost/serialization/shared_ptr.hpp> +#include <boost/serialization/export.hpp> +#include <boost/serialization/split_free.hpp> + +#include "test_tools.hpp" + +#include <set> + +namespace boost { +namespace serialization { + +struct enable_shared_from_this_helper { + std::set<shared_ptr<void> > m_esfth; + void record(boost::shared_ptr<void> sp){ + m_esfth.insert(sp); + } +}; + +template<class Archive, class T> +void serialize( + Archive & ar, + boost::enable_shared_from_this<T> & t, + const unsigned int file_version +){ + enable_shared_from_this_helper & h = + ar.template get_helper< + enable_shared_from_this_helper + >(); + + shared_ptr<T> sp = t.shared_from_this(); + h.record(sp); +} + +} // serialization +} // boost + +class Base { + friend class boost::serialization::access; + + template<class Archive> + void serialize(Archive & ar, const unsigned int version) + { + ar & BOOST_SERIALIZATION_NVP(m_base); + } +protected: + Base() {} + virtual ~Base() {} // "virtual" forces RTTI, to enable serialization of Derived from Base pointer +public: + int m_base; +}; + +class Derived : public Base, public boost::enable_shared_from_this<Derived> { + friend class boost::serialization::access; + + template<class Archive> + void serialize(Archive & ar, const unsigned int version) + { + ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(Base); + ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP( + boost::enable_shared_from_this<Derived> + ); + ar & BOOST_SERIALIZATION_NVP(m_derived); + } +public: + boost::shared_ptr<Derived> SharedPtr() { return shared_from_this(); } + int m_derived; + Derived() {} + ~Derived() {} +}; +// The following is required to enable serialization from Base pointer +BOOST_CLASS_EXPORT(Derived) + +// This test passes +void test_passes(){ + std::stringstream ss; + { + boost::shared_ptr<Derived> d(new Derived()); + d->m_base = 1; + d->m_derived = 2; + + // Get a raw pointer to Derived + Derived* raw_d = d.get(); + + // Verify base and derived members + BOOST_CHECK(raw_d->m_base==1); + BOOST_CHECK(raw_d->m_derived==2); + + // verify shared_from_this + BOOST_CHECK(d == raw_d->SharedPtr()); + + boost::archive::text_oarchive oa(ss); + oa & BOOST_SERIALIZATION_NVP(d); + } + { + // Deserialize it back into a vector of shared_ptr<Derived> + boost::shared_ptr<Derived> d; + ss.seekg(0); + boost::archive::text_iarchive ia(ss); + ia & BOOST_SERIALIZATION_NVP(d); + + // Get a raw pointer to Derived + Derived* raw_d = d.get(); + + // Verify base and derived members + BOOST_CHECK(raw_d->m_base==1); + BOOST_CHECK(raw_d->m_derived==2); + + // verify shared_from_this + BOOST_CHECK(d == raw_d->SharedPtr()); + } +} + +// This test fails +void test_fails(){ + std::stringstream ss; + { + boost::shared_ptr<Base> b(new Derived()); + Derived* raw_d1 = static_cast<Derived*>(b.get()); + raw_d1->m_base = 1; + raw_d1->m_derived = 2; + + // Get a raw pointer to Derived via shared_ptr<Base> + Derived* raw_d = static_cast<Derived*>(b.get()); + + // Verify base and derived members + BOOST_CHECK(raw_d->m_base==1); + BOOST_CHECK(raw_d->m_derived==2); + + // verify shared_from_this + boost::shared_ptr<Derived> d = raw_d->SharedPtr(); + BOOST_CHECK(d == b); + // Serialize the vector + boost::archive::text_oarchive oa(ss); + oa & BOOST_SERIALIZATION_NVP(b); + } + { + // Deserialize it back into a vector of shared_ptr<Base> + ss.seekg(0); + boost::archive::text_iarchive ia(ss); + boost::shared_ptr<Base> b; + ia & BOOST_SERIALIZATION_NVP(b); + + // Get a raw pointer to Derived via shared_ptr<Base> + Derived* raw_d = static_cast<Derived*>(b.get()); + // Verify base and derived members + BOOST_CHECK(raw_d->m_base==1); + BOOST_CHECK(raw_d->m_derived==2); + + // verify shared_from_this + // FAIL: The following line throws bad_weak_ptr exception + boost::shared_ptr<Derived> d = raw_d->SharedPtr(); + BOOST_CHECK(d == b); + } +} + +int test_main(int /*argc*/, char * /*argv */[]){ + test_fails(); + test_passes(); + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_exported.cpp b/src/boost/libs/serialization/test/test_exported.cpp new file mode 100644 index 00000000..726f4362 --- /dev/null +++ b/src/boost/libs/serialization/test/test_exported.cpp @@ -0,0 +1,104 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_exported.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <cstddef> +#include <fstream> + +#include <boost/config.hpp> +#include <cstdio> // remove +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include <boost/serialization/type_info_implementation.hpp> +#include <boost/serialization/export.hpp> +#include <boost/serialization/base_object.hpp> + +#include "test_tools.hpp" + +#include <boost/archive/polymorphic_oarchive.hpp> +#include <boost/archive/polymorphic_iarchive.hpp> + +#include "polymorphic_derived1.hpp" +#include "polymorphic_derived2.hpp" + +// save exported polymorphic class +void save_exported(const char *testfile) +{ + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa_implementation(os, TEST_ARCHIVE_FLAGS); + boost::archive::polymorphic_oarchive & oa_interface = oa_implementation; + + const polymorphic_base *rb1 = new polymorphic_derived1; + const polymorphic_base *rb2 = new polymorphic_derived2; + + // export will permit correct serialization + // through a pointer to a base class + std::cout << "saving polymorphic_derived1 (no_rtti)\n"; + oa_interface << BOOST_SERIALIZATION_NVP(rb1); + + std::cout << "saving polymorphic_derived2\n"; + oa_interface << BOOST_SERIALIZATION_NVP(rb2); + + delete rb1; + delete rb2; +} + +// save exported polymorphic class +void load_exported(const char *testfile) +{ + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia_implementation(is, TEST_ARCHIVE_FLAGS); + boost::archive::polymorphic_iarchive & ia_interface = ia_implementation; + + polymorphic_base *rb1 = NULL; + polymorphic_base *rb2 = NULL; + + // export will permit correct serialization + // through a pointer to a base class + ia_interface >> BOOST_SERIALIZATION_NVP(rb1); + BOOST_CHECK_MESSAGE( + boost::serialization::type_info_implementation<polymorphic_derived1> + ::type::get_const_instance() + == + * boost::serialization::type_info_implementation<polymorphic_base> + ::type::get_const_instance().get_derived_extended_type_info(*rb1), + "restored pointer b1 not of correct type" + ); + + ia_interface >> BOOST_SERIALIZATION_NVP(rb2); + BOOST_CHECK_MESSAGE( + boost::serialization::type_info_implementation<polymorphic_derived2> + ::type::get_const_instance() + == + * boost::serialization::type_info_implementation<polymorphic_base> + ::type::get_const_instance().get_derived_extended_type_info(*rb2), + "restored pointer b2 not of correct type" + ); + + delete rb1; + delete rb2; +} + +int +test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + save_exported(testfile); + load_exported(testfile); + std::remove(testfile); + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_forward_list.cpp b/src/boost/libs/serialization/test/test_forward_list.cpp new file mode 100644 index 00000000..4d6bcd55 --- /dev/null +++ b/src/boost/libs/serialization/test/test_forward_list.cpp @@ -0,0 +1,51 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_forward_list.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <cstddef> // NULL +#include <fstream> +#include <cstdio> // remove +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include <boost/config.hpp> +#include <boost/serialization/forward_list.hpp> + +#include <boost/archive/archive_exception.hpp> +#include "test_tools.hpp" + +#include "A.hpp" +#include "A.ipp" + +int test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + std::forward_list<A> aslist; + aslist.push_front(A()); + aslist.push_front(A()); + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("aslist", aslist); + } + std::forward_list<A> aslist1;{ + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("aslist", aslist1); + } + BOOST_CHECK(aslist == aslist1); + std::remove(testfile); + return EXIT_SUCCESS; +} + +// EOF + diff --git a/src/boost/libs/serialization/test/test_forward_list_ptrs.cpp b/src/boost/libs/serialization/test/test_forward_list_ptrs.cpp new file mode 100644 index 00000000..7071352b --- /dev/null +++ b/src/boost/libs/serialization/test/test_forward_list_ptrs.cpp @@ -0,0 +1,94 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_list.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <cstddef> +#include <fstream> + +#include <boost/config.hpp> +#include <cstdio> // remove +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include <boost/type_traits/is_pointer.hpp> +#include <boost/static_assert.hpp> +#include <boost/checked_delete.hpp> + +#include <boost/archive/archive_exception.hpp> +#include "test_tools.hpp" + +#include <boost/serialization/nvp.hpp> + +#include "A.hpp" +#include "A.ipp" + +template<class T> +struct ptr_equal_to { + BOOST_STATIC_ASSERT(::boost::is_pointer< T >::value); + bool operator()(T const _Left, T const _Right) const + { + if(NULL == _Left && NULL == _Right) + return true; + if(typeid(*_Left) != typeid(*_Right)) + return false; + return *_Left == *_Right; + } +}; + +#include <boost/serialization/forward_list.hpp> +void test_forward_list(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + std::forward_list<A *> aslist; + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + aslist.push_front(new A); + aslist.push_front(new A); + oa << boost::serialization::make_nvp("aslist", aslist); + } + std::forward_list<A *> aslist1; + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("aslist", aslist1); + BOOST_CHECK( + std::equal( + aslist.begin(), + aslist.end(), + aslist1.begin(), + ptr_equal_to<A *>() + ) + ); + } + std::for_each( + aslist.begin(), + aslist.end(), + boost::checked_deleter<A>() + ); + std::for_each( + aslist1.begin(), + aslist1.end(), + boost::checked_deleter<A>() + ); + std::remove(testfile); +} + +int test_main( int /* argc */, char* /* argv */[] ) +{ + test_forward_list(); + + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_helper_support.cpp b/src/boost/libs/serialization/test/test_helper_support.cpp new file mode 100644 index 00000000..cc9dba2e --- /dev/null +++ b/src/boost/libs/serialization/test/test_helper_support.cpp @@ -0,0 +1,129 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_helper_support.cpp + +// (C) Copyright 2008 Joaquin M Lopez Munoz. +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <algorithm> +#include <cstddef> +#include <fstream> + +#include <cstdio> // remove +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include "test_tools.hpp" +#include <boost/lexical_cast.hpp> +#include <boost/serialization/split_free.hpp> +#include <boost/serialization/vector.hpp> +#include <string> +#include <vector> + +// this test uses a special string (my_string) whose contents are shared +// and hence saved in the archive only once. We need a helper in order +// to convert my_string into a serializable type + +class my_string:public std::string +{ + typedef std::string super; + +public: + my_string(){} + my_string(const super & str): super(str){} + my_string & operator=(const super& rhs) { + super::operator=(rhs); + return *this; + } +}; + +struct my_string_helper +{ + typedef std::vector<my_string> table; + table m_t; +}; + +BOOST_SERIALIZATION_SPLIT_FREE(my_string) + +namespace boost { +namespace serialization { + +template<class Archive> +void save(Archive & ar, const my_string & str, const unsigned int /* version */) +{ + void (* const idx)(Archive &, const my_string &, const unsigned int) = & save; + void * const id = reinterpret_cast<void * const>(idx); + my_string_helper & msh = ar.template get_helper<my_string_helper>(id); + + my_string_helper::table t = msh.m_t; + my_string_helper::table::iterator it = std::find(t.begin(), t.end(), str); + if(it == t.end()){ + my_string_helper::table::size_type s = t.size(); + ar << make_nvp("index", s); + t.push_back(str); + ar << make_nvp("string", static_cast<const std::string &>(str)); + } + else{ + my_string_helper::table::size_type s = it - t.begin(); + ar << make_nvp("index", s); + } +} + +template<class Archive> +void load(Archive & ar, my_string & str, const unsigned int /* version */) +{ + void (* const idx)(Archive &, my_string &, const unsigned int) = & load; + void * const id = reinterpret_cast<void * const>(idx); + my_string_helper & msh = ar.template get_helper<my_string_helper>(id); + + my_string_helper::table t = msh.m_t; + + my_string_helper::table::size_type s; + ar >> make_nvp("index", s); + t.reserve(s); + if(s >= t.size()){ + std::string tmp; + ar >> make_nvp("string", tmp); + str = tmp; + t.push_back(str); + } + else{ + str = t[s]; + } +} + +} // namespace serialization +} // namespace boost + +int test_main( int /* argc */, char* /* argv */[] ){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + std::vector<my_string> v1; + for(int i=0; i<1000; ++i){ + v1.push_back(my_string(boost::lexical_cast<std::string>(i % 100))); + } + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("vector", v1); + } + { + std::vector<my_string> v2; + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("vector", v2); + BOOST_CHECK(v1 == v2); + } + std::remove(testfile); + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_inclusion.cpp b/src/boost/libs/serialization/test/test_inclusion.cpp new file mode 100644 index 00000000..33af2869 --- /dev/null +++ b/src/boost/libs/serialization/test/test_inclusion.cpp @@ -0,0 +1,43 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_const.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +#include <boost/serialization/access.hpp> +#include <boost/serialization/base_object.hpp> +#include <boost/serialization/export.hpp> +#include <boost/serialization/level.hpp> +#include <boost/serialization/level_enum.hpp> +#include <boost/serialization/nvp.hpp> +#include <boost/serialization/split_free.hpp> +#include <boost/serialization/split_member.hpp> +#include <boost/serialization/tracking.hpp> +#include <boost/serialization/tracking_enum.hpp> +#include <boost/serialization/traits.hpp> +#include <boost/serialization/type_info_implementation.hpp> +#include <boost/serialization/version.hpp> +#include <boost/serialization/singleton.hpp> + +struct foo +{ + int x; +private: + friend class boost::serialization::access; + + template<class Archive> + void serialize(Archive & ar, const unsigned int version) + { + // In compilers implementing 2-phase lookup, the call to + // make_nvp is resolved even if foo::serialize() is never + // instantiated. + ar & boost::serialization::make_nvp("x",x); + } +}; + +int +main(int /*argc*/, char * /*argv*/[]){ + return 0; +} diff --git a/src/boost/libs/serialization/test/test_inclusion2.cpp b/src/boost/libs/serialization/test/test_inclusion2.cpp new file mode 100644 index 00000000..0bd956e2 --- /dev/null +++ b/src/boost/libs/serialization/test/test_inclusion2.cpp @@ -0,0 +1,25 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_const.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +#include <boost/archive/binary_iarchive.hpp> +#include <boost/serialization/vector.hpp> +#include <sstream> +#include <vector> + +void f() +{ + std::stringstream iss; + boost::archive::binary_iarchive ar(iss); + std::vector<int> out; + ar >> out; +} + +int +main(int /*argc*/, char * /*argv*/[]){ + return 0; +} diff --git a/src/boost/libs/serialization/test/test_interators.cpp b/src/boost/libs/serialization/test/test_interators.cpp new file mode 100644 index 00000000..e69de29b --- /dev/null +++ b/src/boost/libs/serialization/test/test_interators.cpp diff --git a/src/boost/libs/serialization/test/test_interrupts.cpp b/src/boost/libs/serialization/test/test_interrupts.cpp new file mode 100644 index 00000000..fbf1930b --- /dev/null +++ b/src/boost/libs/serialization/test/test_interrupts.cpp @@ -0,0 +1,147 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_array.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <stdlib.h> + +#include <boost/config.hpp> +#include <cstddef> +#include <fstream> +#include <algorithm> // equal +#include <cstdio> // remove +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include "test_tools.hpp" +#include <boost/serialization/nvp.hpp> +#include <boost/serialization/split_member.hpp> +#include <boost/core/no_exceptions_support.hpp> +#include <boost/archive/archive_exception.hpp> + +struct test_dummy_out { + template<class Archive> + void save(Archive &, const unsigned int /*version*/) const { + throw boost::archive::archive_exception( + boost::archive::archive_exception::other_exception + ); + } + template<class Archive> + void load(Archive & ar, const unsigned int version){ + } + BOOST_SERIALIZATION_SPLIT_MEMBER() + test_dummy_out(){} +}; + +template<class T> +int test_out(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + const T t; + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + { + BOOST_TRY { + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + bool exception_invoked = false; + BOOST_TRY { + oa << BOOST_SERIALIZATION_NVP(t); + } + BOOST_CATCH (boost::archive::archive_exception const& ae){ + BOOST_CHECK( + boost::archive::archive_exception::other_exception + == ae.code + ); + exception_invoked = true; + } + BOOST_CATCH_END + BOOST_CHECK(exception_invoked); + } + BOOST_CATCH (boost::archive::archive_exception const& ae){} + BOOST_CATCH_END + } + os.close(); + } + std::remove(testfile); + return EXIT_SUCCESS; +} + +struct test_dummy_in { + template<class Archive> + void save(Archive & /* ar */, const unsigned int /*version*/) const { + } + template<class Archive> + void load(Archive & /* ar */, const unsigned int /*version*/){ + throw boost::archive::archive_exception( + boost::archive::archive_exception::other_exception + ); + } + BOOST_SERIALIZATION_SPLIT_MEMBER() + test_dummy_in(){} +}; + +template<class T> +int test_in(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + const T t; + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + { + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << BOOST_SERIALIZATION_NVP(t); + } + os.close(); + } + { + test_istream is(testfile, TEST_STREAM_FLAGS); + { + T t1; + BOOST_TRY { + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + bool exception_invoked = false; + BOOST_TRY { + ia >> BOOST_SERIALIZATION_NVP(t1); + } + BOOST_CATCH (boost::archive::archive_exception const& ae){ + BOOST_CHECK( + boost::archive::archive_exception::other_exception + == ae.code + ); + exception_invoked = true; + } + BOOST_CATCH_END + BOOST_CHECK(exception_invoked); + } + BOOST_CATCH (boost::archive::archive_exception const& ae){} + BOOST_CATCH_END + } + is.close(); + } + std::remove(testfile); + return EXIT_SUCCESS; +} + +int test_main( int /* argc */, char* /* argv */[] ) +{ + int res; + res = test_out<test_dummy_out>(); + if (res != EXIT_SUCCESS) + return EXIT_FAILURE; + res = test_in<test_dummy_in>(); + if (res != EXIT_SUCCESS) + return EXIT_FAILURE; + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_iterators.cpp b/src/boost/libs/serialization/test/test_iterators.cpp new file mode 100644 index 00000000..048c7949 --- /dev/null +++ b/src/boost/libs/serialization/test/test_iterators.cpp @@ -0,0 +1,257 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_iterators.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +//#include <algorithm> // std::copy, std::equal +#include <vector> +#include <cstdlib> // for rand +#include <functional> +#include <sstream> // used to test stream iterators +#include <clocale> +#include <iterator> // begin +#include <locale> // setlocale + +#include <boost/config.hpp> +#ifdef BOOST_NO_STDC_NAMESPACE +namespace std{ + using ::rand; +} +#endif + +#include <boost/detail/workaround.hpp> +#if BOOST_WORKAROUND(BOOST_DINKUMWARE_STDLIB, == 1) +#include <boost/archive/dinkumware.hpp> +#endif + +#ifndef BOOST_NO_CWCHAR +#include <boost/archive/iterators/mb_from_wchar.hpp> +#include <boost/archive/iterators/wchar_from_mb.hpp> +#endif +#include <boost/archive/iterators/xml_escape.hpp> +#include <boost/archive/iterators/xml_unescape.hpp> +#include <boost/archive/iterators/transform_width.hpp> +#include <boost/archive/iterators/istream_iterator.hpp> +#include <boost/archive/iterators/ostream_iterator.hpp> + +#include "test_tools.hpp" + +#ifndef BOOST_NO_CWCHAR + +void test_wchar_from_mb(const wchar_t *la, const char * a, const unsigned int size){ + typedef boost::archive::iterators::wchar_from_mb<const char *> translator; + BOOST_CHECK(( + std::equal( + translator(a), + translator(a + size), + la + ) + )); +} + +void test_mb_from_wchar(const char * a, const wchar_t *la, const unsigned int size){ + typedef boost::archive::iterators::mb_from_wchar<const wchar_t *> translator; + BOOST_CHECK( + std::equal( + translator(la), + translator(la + size), + a + ) + ); +} + +void test_roundtrip(const wchar_t * la){ + std::size_t s = std::wcslen(la); + std::vector<char> a; + { + typedef boost::archive::iterators::mb_from_wchar<const wchar_t *> translator; + std::copy( + translator(la), + translator(la + s), + std::back_inserter(a) + ); + // note: wchar_from_mb NEEDS a termination null in order to function! + a.push_back(static_cast<char>(0)); + } + BOOST_CHECK(a.size() > 0); + std::vector<wchar_t> la2; + { + typedef boost::archive::iterators::wchar_from_mb<std::vector<char>::const_iterator> translator; + std::copy( + translator(a.begin()), + translator(), + std::back_inserter(la2) + ); + } + BOOST_CHECK(la2.size() == s); + BOOST_CHECK(std::equal(la, la + s, la2.begin())); +} +#endif + +template<class CharType> +void test_xml_escape( + const CharType * xml_escaped, + const CharType * xml, + unsigned int size +){ + typedef boost::archive::iterators::xml_escape<const CharType *> translator; + + BOOST_CHECK( + std::equal( + translator(xml), + translator(xml + size), + xml_escaped + ) + ); +} + +template<class CharType> +void test_xml_unescape( + const CharType * xml, + const CharType * xml_escaped, + unsigned int size +){ + + // test xml_unescape + typedef boost::archive::iterators::xml_unescape<const CharType *> translator; + + BOOST_CHECK( + std::equal( + translator(xml_escaped), + translator(xml_escaped + size), + xml + ) + ); +} + +template<int BitsOut, int BitsIn> +void test_transform_width(unsigned int size){ + // test transform_width + char rawdata[8]; + + char * rptr; + for(rptr = rawdata + size; rptr-- > rawdata;) + *rptr = static_cast<char>(0xff & std::rand()); + + // convert 8 to 6 bit characters + typedef boost::archive::iterators::transform_width< + char *, BitsOut, BitsIn + > translator1; + + std::vector<char> vout; + + std::copy( + translator1(static_cast<char *>(rawdata)), + translator1(rawdata + size), + std::back_inserter(vout) + ); + + // check to see we got the expected # of characters out + if(0 == size) + BOOST_CHECK(vout.size() == 0); + else + BOOST_CHECK(vout.size() == (size * BitsIn - 1 ) / BitsOut + 1); + + typedef boost::archive::iterators::transform_width< + std::vector<char>::iterator, BitsIn, BitsOut + > translator2; + + std::vector<char> vin; + std::copy( + translator2(vout.begin()), + translator2(vout.end()), + std::back_inserter(vin) + ); + + // check to see we got the expected # of characters out + BOOST_CHECK(vin.size() == size); + + BOOST_CHECK( + std::equal( + rawdata, + rawdata + size, + vin.begin() + ) + ); +} + +template<class CharType> +void test_stream_iterators( + const CharType * test_data, + unsigned int size +){ + std::basic_stringstream<CharType> ss; + boost::archive::iterators::ostream_iterator<CharType> osi = + boost::archive::iterators::ostream_iterator<CharType>(ss); + std::copy(test_data, test_data + size, osi); + + BOOST_CHECK(size == ss.str().size()); + + boost::archive::iterators::istream_iterator<CharType> isi = + boost::archive::iterators::istream_iterator<CharType>(ss); + BOOST_CHECK(std::equal(test_data, test_data + size,isi)); +} + +int +test_main(int /* argc */, char* /* argv */ [] ) +{ + const char xml[] = "<+>+&+\"+'"; + const char xml_escaped[] = "<+>+&+"+'"; + test_xml_escape<const char>( + xml_escaped, + xml, + sizeof(xml) / sizeof(char) - 1 + ); + test_xml_unescape<const char>( + xml, + xml_escaped, + sizeof(xml_escaped) / sizeof(char) - 1 + ); + + + #ifndef BOOST_NO_CWCHAR + const wchar_t wxml[] = L"<+>+&+\"+'"; + const wchar_t wxml_escaped[] = L"<+>+&+"+'"; + test_xml_escape<const wchar_t>( + wxml_escaped, + wxml, + sizeof(wxml) / sizeof(wchar_t) - 1 + ); + test_xml_unescape<const wchar_t>( + wxml, + wxml_escaped, + sizeof(wxml_escaped) / sizeof(wchar_t) - 1 + ); + + const char b[] = "abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyz"; + const wchar_t lb[] = L"abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyz"; + test_mb_from_wchar(b, lb, sizeof(lb) / sizeof(wchar_t) - 1); + test_wchar_from_mb(lb, b, sizeof(b) / sizeof(char) - 1); + + const char a[] = "abcdefghijklmnopqrstuvwxyz"; + const wchar_t la[] = L"abcdefghijklmnopqrstuvwxyz"; + test_mb_from_wchar(a, la, sizeof(la) / sizeof(wchar_t) - 1); + test_wchar_from_mb(la, a, sizeof(a) / sizeof(char) - 1); + + test_roundtrip(L"z\u00df\u6c34\U0001f34c"); + + test_stream_iterators<wchar_t>(la, sizeof(la)/sizeof(wchar_t) - 1); + #endif + + test_stream_iterators<char>(a, sizeof(a) - 1); + + test_transform_width<6, 8>(0); + test_transform_width<6, 8>(1); + test_transform_width<6, 8>(2); + test_transform_width<6, 8>(3); + test_transform_width<6, 8>(4); + test_transform_width<6, 8>(5); + test_transform_width<6, 8>(6); + test_transform_width<6, 8>(7); + test_transform_width<6, 8>(8); + + return EXIT_SUCCESS; +} diff --git a/src/boost/libs/serialization/test/test_iterators_base64.cpp b/src/boost/libs/serialization/test/test_iterators_base64.cpp new file mode 100644 index 00000000..cdfeabce --- /dev/null +++ b/src/boost/libs/serialization/test/test_iterators_base64.cpp @@ -0,0 +1,105 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_iterators.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +#include <algorithm> +#include <list> + +#if (defined _MSC_VER) && (_MSC_VER == 1200) +# pragma warning (disable : 4786) // too long name, harmless warning +#endif + +#include <cstdlib> +#include <cstddef> // size_t + +#include <boost/config.hpp> +#ifdef BOOST_NO_STDC_NAMESPACE +namespace std{ + using ::rand; + using ::size_t; +} +#endif + +#include <boost/archive/iterators/binary_from_base64.hpp> +#include <boost/archive/iterators/base64_from_binary.hpp> +#include <boost/archive/iterators/insert_linebreaks.hpp> +#include <boost/archive/iterators/remove_whitespace.hpp> +#include <boost/archive/iterators/transform_width.hpp> + +#include "test_tools.hpp" + +#include <iostream> + +template<typename CharType> +void test_base64(unsigned int size){ + CharType rawdata[150]; + CharType * rptr; + for(rptr = rawdata + size; rptr-- > rawdata;) + *rptr = static_cast<CharType>(std::rand()& 0xff); + + // convert to base64 + typedef std::list<CharType> text_base64_type; + text_base64_type text_base64; + + typedef + boost::archive::iterators::insert_linebreaks< + boost::archive::iterators::base64_from_binary< + boost::archive::iterators::transform_width< + CharType * + ,6 + ,sizeof(CharType) * 8 + > + > + ,76 + > + translate_out; + + std::copy( + translate_out(static_cast<CharType *>(rawdata)), + translate_out(rawdata + size), + std::back_inserter(text_base64) + ); + + // convert from base64 to binary and compare with the original + typedef + boost::archive::iterators::transform_width< + boost::archive::iterators::binary_from_base64< + boost::archive::iterators::remove_whitespace< + typename text_base64_type::iterator + > + >, + sizeof(CharType) * 8, + 6 + > translate_in; + + BOOST_CHECK( + std::equal( + rawdata, + rawdata + size, + translate_in(text_base64.begin()) + ) + ); + +} + +int +test_main( int /*argc*/, char* /*argv*/[] ) +{ + test_base64<char>(1); + test_base64<char>(2); + test_base64<char>(3); + test_base64<char>(4); + test_base64<char>(150); + #ifndef BOOST_NO_CWCHAR + test_base64<wchar_t>(1); + test_base64<wchar_t>(2); + test_base64<wchar_t>(3); + test_base64<wchar_t>(4); + test_base64<wchar_t>(150); + #endif + return EXIT_SUCCESS; +} diff --git a/src/boost/libs/serialization/test/test_list.cpp b/src/boost/libs/serialization/test/test_list.cpp new file mode 100644 index 00000000..81b8cf9c --- /dev/null +++ b/src/boost/libs/serialization/test/test_list.cpp @@ -0,0 +1,59 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_list.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <cstddef> // NULL +#include <fstream> + +#include <boost/config.hpp> +#include <cstdio> // remove +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include <boost/archive/archive_exception.hpp> +#include "test_tools.hpp" + +#include "A.hpp" +#include "A.ipp" + +#include <boost/serialization/list.hpp> +void test_list(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + std::list<A> alist; + alist.push_back(A()); + alist.push_back(A()); + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("alist",alist); + } + + std::list<A> alist1; + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("alist",alist1); + } + BOOST_CHECK(alist == alist1); + std::remove(testfile); +} + +int test_main( int /* argc */, char* /* argv */[] ) +{ + test_list(); + return EXIT_SUCCESS; +} + +// EOF + diff --git a/src/boost/libs/serialization/test/test_list_ptrs.cpp b/src/boost/libs/serialization/test/test_list_ptrs.cpp new file mode 100644 index 00000000..ede26880 --- /dev/null +++ b/src/boost/libs/serialization/test/test_list_ptrs.cpp @@ -0,0 +1,98 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_list.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <cstddef> +#include <fstream> + +#include <boost/config.hpp> +#include <cstdio> // remove +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include <boost/type_traits/is_pointer.hpp> +#include <boost/static_assert.hpp> +#include <boost/checked_delete.hpp> + +#include <boost/archive/archive_exception.hpp> +#include "test_tools.hpp" + +#include <boost/serialization/nvp.hpp> + +#include "A.hpp" +#include "A.ipp" + +template<class T> +struct ptr_equal_to { + BOOST_STATIC_ASSERT(::boost::is_pointer< T >::value); + bool operator()(T const _Left, T const _Right) const + { + if(NULL == _Left && NULL == _Right) + return true; + if(typeid(*_Left) != typeid(*_Right)) + return false; + return *_Left == *_Right; + } +}; + +#include <boost/serialization/list.hpp> +void test_list(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + std::list<A *> alist; + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + A * free_a_ptr = new A; + alist.push_back(free_a_ptr); + alist.push_back(new A); + // verify that first element is the same as the free pointer + BOOST_CHECK((*alist.begin()) == free_a_ptr); + oa << boost::serialization::make_nvp("alist", alist); + oa << boost::serialization::make_nvp("free_a_ptr", free_a_ptr); + } + std::list<A *> alist1; + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + A * free_a_ptr1; + ia >> boost::serialization::make_nvp("alist", alist1); + ia >> boost::serialization::make_nvp("free_a_ptr", free_a_ptr1); + BOOST_CHECK( + alist.size() == alist1.size() + && std::equal(alist.begin(),alist.end(),alist1.begin(),ptr_equal_to<A *>()) + ); + // verify that first element is the same as the free pointer + BOOST_CHECK((*alist1.begin()) == free_a_ptr1); + } + + std::for_each( + alist.begin(), + alist.end(), + boost::checked_deleter<A>() + ); + std::for_each( + alist1.begin(), + alist1.end(), + boost::checked_deleter<A>() + ); + std::remove(testfile); +} + +int test_main( int /* argc */, char* /* argv */[] ) +{ + test_list(); + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_map.cpp b/src/boost/libs/serialization/test/test_map.cpp new file mode 100644 index 00000000..66e6f885 --- /dev/null +++ b/src/boost/libs/serialization/test/test_map.cpp @@ -0,0 +1,149 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_map.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// (C) Copyright 2014 Jim Bell +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <algorithm> // std::copy +#include <vector> +#include <fstream> +#include <cstddef> // size_t, NULL + +#include <boost/config.hpp> +#include <boost/detail/workaround.hpp> + +#include <cstdio> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::rand; + using ::size_t; +} +#endif + +#include "test_tools.hpp" + +#include <boost/serialization/nvp.hpp> +#include <boost/serialization/map.hpp> + +#include "A.hpp" +#include "A.ipp" + +/////////////////////////////////////////////////////// +// a key value initialized with a random value for use +// in testing STL map serialization +struct random_key { + friend class boost::serialization::access; + template<class Archive> + void serialize( + Archive & ar, + const unsigned int /* file_version */ + ){ + ar & boost::serialization::make_nvp("random_key", m_i); + } + int m_i; + random_key() : m_i(std::rand()){}; + bool operator<(const random_key &rhs) const { + return m_i < rhs.m_i; + } + bool operator==(const random_key &rhs) const { + return m_i == rhs.m_i; + } + operator std::size_t () const { // required by hash_map + return m_i; + } +}; + +void +test_map(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + BOOST_MESSAGE("map"); + // test map of objects + std::map<random_key, A> amap; + amap.insert(std::make_pair(random_key(), A())); + amap.insert(std::make_pair(random_key(), A())); + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("amap", amap); + } + std::map<random_key, A> amap1; + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("amap", amap1); + } + BOOST_CHECK(amap == amap1); + std::remove(testfile); +} + +void +test_map_2(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + BOOST_MESSAGE("map_2"); + std::pair<int, int> a(11, 22); + std::map<int, int> b; + b[0] = 0; + b[-1] = -1; + b[1] = 1; + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + std::pair<int, int> * const pa = &a; + std::map<int, int> * const pb = &b; + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << BOOST_SERIALIZATION_NVP(pb); + oa << BOOST_SERIALIZATION_NVP(pa); + } + { + test_istream is(testfile, TEST_STREAM_FLAGS); + std::pair<int, int> *pa = 0; + std::map<int, int> *pb = 0; + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> BOOST_SERIALIZATION_NVP(pb); + ia >> BOOST_SERIALIZATION_NVP(pa); + delete pa; + delete pb; + } + std::remove(testfile); +} + +void +test_multimap(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + BOOST_MESSAGE("multimap"); + std::multimap<random_key, A> amultimap; + amultimap.insert(std::make_pair(random_key(), A())); + amultimap.insert(std::make_pair(random_key(), A())); + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("amultimap", amultimap); + } + std::multimap<random_key, A> amultimap1; + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("amultimap", amultimap1); + } + BOOST_CHECK(amultimap == amultimap1); + std::remove(testfile); +} + +int test_main( int /* argc */, char* /* argv */[] ) +{ + test_map(); + test_map_2(); + test_multimap(); + + return EXIT_SUCCESS; +} diff --git a/src/boost/libs/serialization/test/test_map_boost_unordered.cpp b/src/boost/libs/serialization/test/test_map_boost_unordered.cpp new file mode 100644 index 00000000..5af31e16 --- /dev/null +++ b/src/boost/libs/serialization/test/test_map_boost_unordered.cpp @@ -0,0 +1,142 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_map.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// (C) Copyright 2014 Jim Bell +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <algorithm> // std::copy +#include <vector> +#include <fstream> +#include <cstddef> // size_t, NULL + +#include <boost/config.hpp> +#include <boost/detail/workaround.hpp> + +#include <cstdio> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::rand; + using ::size_t; +} +#endif + +#include "test_tools.hpp" + +#include <boost/serialization/nvp.hpp> +#include <boost/serialization/map.hpp> + +#include "A.hpp" +#include "A.ipp" + +/////////////////////////////////////////////////////// +// a key value initialized with a random value for use +// in testing STL map serialization +struct random_key { + friend class boost::serialization::access; + template<class Archive> + void serialize( + Archive & ar, + const unsigned int /* file_version */ + ){ + ar & boost::serialization::make_nvp("random_key", m_i); + } + int m_i; + random_key() : m_i(std::rand()){}; + bool operator<(const random_key &rhs) const { + return m_i < rhs.m_i; + } + bool operator==(const random_key &rhs) const { + return m_i == rhs.m_i; + } + operator std::size_t () const { // required by hash_map + return m_i; + } +}; + +#include <boost/serialization/boost_unordered_map.hpp> +#include <functional> // requires changeset [69520]; Ticket #5254 + +namespace boost { + template<> + struct hash<random_key>{ + std::size_t operator()(const random_key& r) const { + return static_cast<std::size_t>(r); + } + }; +} // namespace std + +void +test_unordered_map(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + BOOST_CHECKPOINT("unordered_map"); + // test unordered_map of objects + boost::unordered_map<random_key, A> anunordered_map; + anunordered_map.insert(std::make_pair(random_key(), A())); + anunordered_map.insert(std::make_pair(random_key(), A())); + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("anunorderedmap",anunordered_map); + } + boost::unordered_map<random_key, A> anunordered_map1; + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("anunorderedmap",anunordered_map1); + } + + std::vector< std::pair<random_key, A> > tvec, tvec1; + std::copy(anunordered_map.begin(), anunordered_map.end(), std::back_inserter(tvec)); + std::sort(tvec.begin(), tvec.end()); + std::copy(anunordered_map1.begin(), anunordered_map1.end(), std::back_inserter(tvec1)); + std::sort(tvec1.begin(), tvec1.end()); + BOOST_CHECK(tvec == tvec1); + + std::remove(testfile); +} + +void +test_unordered_multimap(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + BOOST_CHECKPOINT("unordered_multimap"); + boost::unordered_multimap<random_key, A> anunordered_multimap; + anunordered_multimap.insert(std::make_pair(random_key(), A())); + anunordered_multimap.insert(std::make_pair(random_key(), A())); + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("anunordered_multimap", anunordered_multimap); + } + boost::unordered_multimap<random_key, A> anunordered_multimap1; + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("anunordered_multimap", anunordered_multimap1); + } + std::vector< std::pair<random_key, A> > tvec, tvec1; + tvec.clear(); + tvec1.clear(); + std::copy(anunordered_multimap.begin(), anunordered_multimap.end(), std::back_inserter(tvec)); + std::sort(tvec.begin(), tvec.end()); + std::copy(anunordered_multimap1.begin(), anunordered_multimap1.end(), std::back_inserter(tvec1)); + std::sort(tvec1.begin(), tvec1.end()); + BOOST_CHECK(tvec == tvec1); + std::remove(testfile); +} + +int test_main( int /* argc */, char* /* argv */[] ) +{ + test_unordered_map(); + test_unordered_multimap(); + + return EXIT_SUCCESS; +} diff --git a/src/boost/libs/serialization/test/test_map_hashed.cpp b/src/boost/libs/serialization/test/test_map_hashed.cpp new file mode 100644 index 00000000..3fcb902c --- /dev/null +++ b/src/boost/libs/serialization/test/test_map_hashed.cpp @@ -0,0 +1,139 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_map.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// (C) Copyright 2014 Jim Bell +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <algorithm> // std::copy +#include <vector> +#include <fstream> +#include <cstddef> // size_t, NULL + +#include <boost/config.hpp> +#include <boost/detail/workaround.hpp> + +#include <cstdio> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::rand; + using ::size_t; +} +#endif + +#include "test_tools.hpp" + +#include <boost/serialization/nvp.hpp> +#include <boost/serialization/map.hpp> + +#include "A.hpp" +#include "A.ipp" + +/////////////////////////////////////////////////////// +// a key value initialized with a random value for use +// in testing STL map serialization +struct random_key { + friend class boost::serialization::access; + template<class Archive> + void serialize( + Archive & ar, + const unsigned int /* file_version */ + ){ + ar & boost::serialization::make_nvp("random_key", m_i); + } + int m_i; + random_key() : m_i(std::rand()){}; + bool operator<(const random_key &rhs) const { + return m_i < rhs.m_i; + } + bool operator==(const random_key &rhs) const { + return m_i == rhs.m_i; + } + operator std::size_t () const { // required by hash_map + return m_i; + } +}; + +#include <boost/serialization/hash_map.hpp> + +namespace BOOST_STD_EXTENSION_NAMESPACE { + template<> + struct hash<random_key>{ + std::size_t operator()(const random_key& r) const { + return static_cast<std::size_t>(r); + } + }; +} // namespace BOOST_STD_EXTENSION_NAMESPACE + +void +test_hash_map(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + BOOST_CHECKPOINT("hash_map"); + // test hash_map of objects + BOOST_STD_EXTENSION_NAMESPACE::hash_map<random_key, A> ahash_map; + ahash_map.insert(std::make_pair(random_key(), A())); + ahash_map.insert(std::make_pair(random_key(), A())); + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("ahashmap",ahash_map); + } + BOOST_STD_EXTENSION_NAMESPACE::hash_map<random_key, A> ahash_map1; + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("ahashmap",ahash_map1); + } + + std::vector< std::pair<random_key, A> > tvec, tvec1; + std::copy(ahash_map.begin(), ahash_map.end(), std::back_inserter(tvec)); + std::sort(tvec.begin(), tvec.end()); + std::copy(ahash_map1.begin(), ahash_map1.end(), std::back_inserter(tvec1)); + std::sort(tvec1.begin(), tvec1.end()); + BOOST_CHECK(tvec == tvec1); + + std::remove(testfile); +} + +void +test_hash_multimap(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + BOOST_CHECKPOINT("hash_multimap"); + BOOST_STD_EXTENSION_NAMESPACE::hash_multimap<random_key, A> ahash_multimap; + ahash_multimap.insert(std::make_pair(random_key(), A())); + ahash_multimap.insert(std::make_pair(random_key(), A())); + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("ahash_multimap", ahash_multimap); + } + BOOST_STD_EXTENSION_NAMESPACE::hash_multimap<random_key, A> ahash_multimap1; + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("ahash_multimap", ahash_multimap1); + } + std::vector< std::pair<random_key, A> > tvec, tvec1; + tvec.clear(); + tvec1.clear(); + std::copy(ahash_multimap.begin(), ahash_multimap.end(), std::back_inserter(tvec)); + std::sort(tvec.begin(), tvec.end()); + std::copy(ahash_multimap1.begin(), ahash_multimap1.end(), std::back_inserter(tvec1)); + std::sort(tvec1.begin(), tvec1.end()); + BOOST_CHECK(tvec == tvec1); + std::remove(testfile); +} +int test_main( int /* argc */, char* /* argv */[] ) +{ + test_hash_map(); + test_hash_multimap(); + return EXIT_SUCCESS; +} diff --git a/src/boost/libs/serialization/test/test_map_unordered.cpp b/src/boost/libs/serialization/test/test_map_unordered.cpp new file mode 100644 index 00000000..488e928a --- /dev/null +++ b/src/boost/libs/serialization/test/test_map_unordered.cpp @@ -0,0 +1,142 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_map.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// (C) Copyright 2014 Jim Bell +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <algorithm> // std::copy +#include <vector> +#include <fstream> +#include <cstddef> // size_t, NULL + +#include <boost/config.hpp> +#include <boost/detail/workaround.hpp> + +#include <cstdio> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::rand; + using ::size_t; +} +#endif + +#include "test_tools.hpp" + +#include <boost/serialization/nvp.hpp> +#include <boost/serialization/map.hpp> + +#include "A.hpp" +#include "A.ipp" + +/////////////////////////////////////////////////////// +// a key value initialized with a random value for use +// in testing STL map serialization +struct random_key { + friend class boost::serialization::access; + template<class Archive> + void serialize( + Archive & ar, + const unsigned int /* file_version */ + ){ + ar & boost::serialization::make_nvp("random_key", m_i); + } + int m_i; + random_key() : m_i(std::rand()){}; + bool operator<(const random_key &rhs) const { + return m_i < rhs.m_i; + } + bool operator==(const random_key &rhs) const { + return m_i == rhs.m_i; + } + operator std::size_t () const { // required by hash_map + return m_i; + } +}; + +#include <boost/serialization/unordered_map.hpp> +#include <functional> // requires changeset [69520]; Ticket #5254 + +namespace std { + template<> + struct hash<random_key>{ + std::size_t operator()(const random_key& r) const { + return static_cast<std::size_t>(r); + } + }; +} // namespace std + +void +test_unordered_map(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + BOOST_CHECKPOINT("unordered_map"); + // test unordered_map of objects + std::unordered_map<random_key, A> anunordered_map; + anunordered_map.insert(std::make_pair(random_key(), A())); + anunordered_map.insert(std::make_pair(random_key(), A())); + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("anunorderedmap",anunordered_map); + } + std::unordered_map<random_key, A> anunordered_map1; + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("anunorderedmap",anunordered_map1); + } + + std::vector< std::pair<random_key, A> > tvec, tvec1; + std::copy(anunordered_map.begin(), anunordered_map.end(), std::back_inserter(tvec)); + std::sort(tvec.begin(), tvec.end()); + std::copy(anunordered_map1.begin(), anunordered_map1.end(), std::back_inserter(tvec1)); + std::sort(tvec1.begin(), tvec1.end()); + BOOST_CHECK(tvec == tvec1); + + std::remove(testfile); +} + +void +test_unordered_multimap(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + BOOST_CHECKPOINT("unordered_multimap"); + std::unordered_multimap<random_key, A> anunordered_multimap; + anunordered_multimap.insert(std::make_pair(random_key(), A())); + anunordered_multimap.insert(std::make_pair(random_key(), A())); + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("anunordered_multimap", anunordered_multimap); + } + std::unordered_multimap<random_key, A> anunordered_multimap1; + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("anunordered_multimap", anunordered_multimap1); + } + std::vector< std::pair<random_key, A> > tvec, tvec1; + tvec.clear(); + tvec1.clear(); + std::copy(anunordered_multimap.begin(), anunordered_multimap.end(), std::back_inserter(tvec)); + std::sort(tvec.begin(), tvec.end()); + std::copy(anunordered_multimap1.begin(), anunordered_multimap1.end(), std::back_inserter(tvec1)); + std::sort(tvec1.begin(), tvec1.end()); + BOOST_CHECK(tvec == tvec1); + std::remove(testfile); +} + +int test_main( int /* argc */, char* /* argv */[] ) +{ + test_unordered_map(); + test_unordered_multimap(); + + return EXIT_SUCCESS; +} diff --git a/src/boost/libs/serialization/test/test_mi.cpp b/src/boost/libs/serialization/test/test_mi.cpp new file mode 100644 index 00000000..22e6454d --- /dev/null +++ b/src/boost/libs/serialization/test/test_mi.cpp @@ -0,0 +1,135 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_mi.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// test of serialization of base classes with multiple inheritance +// contributed by Peter Dimov + +#include <cstddef> +#include <iostream> +#include <fstream> + +#include <boost/config.hpp> +#include <cstdio> // remove +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include "test_tools.hpp" + +#include <boost/serialization/nvp.hpp> +#include <boost/serialization/base_object.hpp> + +class A +{ +private: + friend class boost::serialization::access; + int x; + template<class Archive> + void serialize(Archive &ar, const unsigned int /* file_version */){ + ar & BOOST_SERIALIZATION_NVP(x); + } +public: + explicit A(int x = 0): x(x) {} + virtual ~A(); // = 0; + int get_x() const + { + return x; + } +}; + +inline A::~A() +{ +} + +class B +{ +private: + int y; + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive &ar, const unsigned int /* file_version */){ + ar & BOOST_SERIALIZATION_NVP(y); + } +public: + explicit B(int y = 0): y(y) {} + virtual ~B(){} + int get_y() const + { + return y; + } +}; + +class C: public A, public B +{ +private: + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive &ar, const unsigned int /* file_version */){ + ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(A); + ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(B); + } +public: + C(){} + C(int x, int y): A(x), B(y){} +}; + +int +test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + C * pc = new C(1, 2); + A * pa = pc; + B * pb = pc; + + BOOST_CHECK(pa == pc); + BOOST_CHECK(pb == pc); + + int x = pa->get_x(); + int y = pb->get_y(); + + std::cout << "pa->get_x(): " << pa->get_x() << std::endl; + std::cout << "pb->get_y(): " << pb->get_y() << std::endl; + + { + test_ostream ofs(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(ofs); + oa << BOOST_SERIALIZATION_NVP(pc); + oa << BOOST_SERIALIZATION_NVP(pa); + oa << BOOST_SERIALIZATION_NVP(pb); + } + + delete pc; + pc = NULL; + pa = NULL; + pb = NULL; + + { + test_istream ifs(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(ifs); + ia >> BOOST_SERIALIZATION_NVP(pc); + ia >> BOOST_SERIALIZATION_NVP(pa); + ia >> BOOST_SERIALIZATION_NVP(pb); + } + + BOOST_CHECK(pa == pc); + BOOST_CHECK(pb == pc); + + BOOST_CHECK(x == pa->get_x()); + BOOST_CHECK(y == pb->get_y()); + + std::cout << "pa->get_x(): " << pa->get_x() << std::endl; + std::cout << "pb->get_y(): " << pb->get_y() << std::endl; + + delete pc; + std::remove(testfile); + return EXIT_SUCCESS; +} diff --git a/src/boost/libs/serialization/test/test_mult_archive_types.cpp b/src/boost/libs/serialization/test/test_mult_archive_types.cpp new file mode 100644 index 00000000..66915323 --- /dev/null +++ b/src/boost/libs/serialization/test/test_mult_archive_types.cpp @@ -0,0 +1,124 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_mult_archive_types.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +#include <cstddef> +#include <fstream> + +#include <boost/config.hpp> +#include <cstdio> // remove +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include <boost/archive/text_oarchive.hpp> +#include <boost/archive/text_iarchive.hpp> +#include <boost/archive/xml_oarchive.hpp> +#include <boost/archive/xml_iarchive.hpp> +#include "test_tools.hpp" + +#include <boost/serialization/export.hpp> +#include <boost/serialization/nvp.hpp> + +// This is a simple class. It contains a counter of the number +// of objects of this class which have been instantiated. +class A +{ +private: + friend class boost::serialization::access; + int x; + template<class Archive> + void serialize(Archive & ar, const unsigned int /* file_version */){ + ar & BOOST_SERIALIZATION_NVP(x); + } +public: + static int count; + A(){++count;} // default constructor + virtual ~A(){--count;} // default destructor +}; + +BOOST_CLASS_EXPORT(A) + +// B is a subclass of A +class B : public A +{ +private: + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive & ar, const unsigned int /* file_version */){ + ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(A); + } +public: + static int count; + B() : A() {}; + virtual ~B() {}; +}; + +BOOST_CLASS_EXPORT(B) + +int A::count = 0; + +// Run tests by serializing two shared_ptrs into an archive of type +// OARCH, clearing them (deleting the objects) and then reloading the +// objects back from an archive of type OARCH. +template<class OA, class IA> +void test_save_and_load(A * first, A * second) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + // Save + { + std::ofstream os(testfile); + OA oa(os); + oa << BOOST_SERIALIZATION_NVP(first); + oa << BOOST_SERIALIZATION_NVP(second); + } + + // Clear the pointers, thereby destroying the objects they contain + first = NULL; + second = NULL; + + // Load + { + std::ifstream is(testfile); + IA ia(is); + ia >> BOOST_SERIALIZATION_NVP(first); + ia >> BOOST_SERIALIZATION_NVP(second); + } + BOOST_CHECK(first == second); + std::remove(testfile); +} + +using namespace boost::archive; + +// This does the tests +int test_main(int /* argc */, char * /* argv */[]) +{ + // Try to save and load pointers to As, to a text archive + A * a = new A; + A * a1 = a; + test_save_and_load<text_oarchive, text_iarchive>(a, a1); + + // Try to save and load pointers to Bs, to a text archive + B * b = new B; + B * b1 = b; + test_save_and_load<text_oarchive, text_iarchive>(b, b1); + + // Try to save and load pointers to As, to an xml archive + test_save_and_load<xml_oarchive, xml_iarchive>(a, a1); + + // Try to save and load pointers to Bs, to an xml archive + test_save_and_load<xml_oarchive, xml_iarchive>(b, b1); + + delete a; + delete b; + + return EXIT_SUCCESS; +} diff --git a/src/boost/libs/serialization/test/test_multi_shared_lib.cpp b/src/boost/libs/serialization/test/test_multi_shared_lib.cpp new file mode 100644 index 00000000..978e9591 --- /dev/null +++ b/src/boost/libs/serialization/test/test_multi_shared_lib.cpp @@ -0,0 +1,30 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_multi_shared_lib.cpp: test that implementation of extented_type_info +// works when using multiple shared libraries +// +// This reproduces a crash that occurred when multiple shared libraries were +// using Boost.Serialization built statically. That causes core singletons to be +// instantiated in each shared library separately. Due to some destruction order +// mixup in the context of shared libraries on linux it is possible, that +// singletons accessed in destructors of other singletons are already destructed. +// Accessing them will then lead to a crash or memory corruption. +// For this we need 2 shared libraries, linked against static boost. They need to +// instantiate extended_type_info_typeid with different types, either by serializing +// 2 types (which will do that internally) or by accessing the singletons directly. + +// (C) Copyright 2018 Alexander Grund +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +#include <boost/serialization/config.hpp> + +// Both shall instantiate different(!) singletons and return true +BOOST_SYMBOL_IMPORT bool f(); +BOOST_SYMBOL_IMPORT bool g(); + +int main(int argc, char**){ + if(f() && g()) + return 0; + return 1; +} diff --git a/src/boost/libs/serialization/test/test_multiple_inheritance.cpp b/src/boost/libs/serialization/test/test_multiple_inheritance.cpp new file mode 100644 index 00000000..06535195 --- /dev/null +++ b/src/boost/libs/serialization/test/test_multiple_inheritance.cpp @@ -0,0 +1,125 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_multiple_inheritance.cpp + +// (C) Copyright 2009 Robert Ramey. +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// test of serialization library for multiple inheritence situations + +#include <cassert> +#include <fstream> + +#include <boost/config.hpp> +#include <cstdio> // remove +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include "test_tools.hpp" + +#include <boost/serialization/access.hpp> +#include <boost/serialization/base_object.hpp> +#include <boost/serialization/nvp.hpp> +#include <boost/serialization/export.hpp> + +struct Base1 { + int m_x; + Base1(){} + Base1(int x) : m_x(1 + x) {} + virtual ~Base1() {} + bool operator==(Base1 & rhs) const { + return m_x == rhs.m_x; + } + // serialize + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive & ar, const unsigned int /* file_version */) { + ar & BOOST_SERIALIZATION_NVP(m_x); + } +}; + +//BOOST_CLASS_EXPORT(Base1) + +struct Base2 { + int m_x; + Base2(){} + Base2(int x) : m_x(2 + x) {} + virtual ~Base2() {} + bool operator==(Base2 & rhs) const { + return m_x == rhs.m_x; + } + // serialize + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive & ar, const unsigned int /* file_version */) { + ar & BOOST_SERIALIZATION_NVP(m_x); + } +}; + +//BOOST_CLASS_EXPORT(Base2) + +struct Sub : + public Base1, + public Base2 +{ + int m_x; + Sub(){} + Sub(int x) : + Base1(x), + Base2(x), + m_x(x) + {} + bool operator==(Sub & rhs) const { + if(! Base2::operator==(rhs)) + return false; + if(! Base1::operator==(rhs)) + return false; + return m_x == rhs.m_x; + } + virtual ~Sub() {} + + // serialize + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive &ar, const unsigned int /* file_version */) + { + ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(Base1); + ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(Base2); + ar & BOOST_SERIALIZATION_NVP(m_x); + } +}; + +BOOST_CLASS_EXPORT(Sub) + +int +test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + Base2 * pb2; + { + // serialize + pb2 = new Sub(2); + + test_ostream ofs(testfile); + test_oarchive oa(ofs); + oa << boost::serialization::make_nvp("Base2", pb2); + } + Base2 * pb2_1; + { + // de-serialize + test_istream ifs(testfile); + test_iarchive ia(ifs); + ia >> boost::serialization::make_nvp("Base2", pb2_1); + } + Sub *s1 = dynamic_cast<Sub *>(pb2); + BOOST_CHECK(0 != s1); + Sub *s2 = dynamic_cast<Sub *>(pb2_1); + BOOST_CHECK(0 != s2); + BOOST_CHECK(*s1 == *s2); + return EXIT_SUCCESS; +} diff --git a/src/boost/libs/serialization/test/test_multiple_ptrs.cpp b/src/boost/libs/serialization/test/test_multiple_ptrs.cpp new file mode 100644 index 00000000..df1e5fba --- /dev/null +++ b/src/boost/libs/serialization/test/test_multiple_ptrs.cpp @@ -0,0 +1,50 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_archive_derivation.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <cstddef> +#include <fstream> + +#include <boost/config.hpp> +#include <cstdio> // remove +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include "test_tools.hpp" + +#include "D.hpp" +#include "A.ipp" + +int test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + const A a; + A a1; + + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("a", a); + } + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("a", a1); + } + BOOST_CHECK(a == a1); + std::remove(testfile); + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_native_array.cpp b/src/boost/libs/serialization/test/test_native_array.cpp new file mode 100644 index 00000000..228f537a --- /dev/null +++ b/src/boost/libs/serialization/test/test_native_array.cpp @@ -0,0 +1,103 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_array.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <stdlib.h> + +#include <boost/config.hpp> +#include <cstddef> +#include <fstream> +#include <algorithm> // equal +#include <cstdio> // remove +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif +#include "test_tools.hpp" +#include <boost/core/no_exceptions_support.hpp> +#include <boost/archive/archive_exception.hpp> + +#include "A.hpp" +#include "A.ipp" + +template <class T> +int test_native_array(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + // test array of objects + const T a_array[10]={T(),T(),T(),T(),T(),T(),T(),T(),T(),T()}; + const T b_array[2][3]={{T(),T(),T()},{T(),T(),T()}}; + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + { + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("a_array", a_array); + oa << boost::serialization::make_nvp("b_array", b_array); + } + os.close(); + } + { + T a_array1[10]; + T b_array1[2][3]; + test_istream is(testfile, TEST_STREAM_FLAGS); + { + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("a_array", a_array1); + ia >> boost::serialization::make_nvp("b_array", b_array1); + } + is.close(); + BOOST_CHECK(std::equal(& a_array[0], & a_array[10], & a_array1[0])); + BOOST_CHECK(b_array[0][0] == b_array1[0][0]); + BOOST_CHECK(b_array[1][0] == b_array1[1][0]); + } + { + T a_array1[9]; + T b_array1[2][3]; + test_istream is(testfile, TEST_STREAM_FLAGS); + { + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + bool exception_invoked = false; + BOOST_TRY { + ia >> boost::serialization::make_nvp("a_array", a_array1); + ia >> boost::serialization::make_nvp("b_array", b_array1); + } + BOOST_CATCH (boost::archive::archive_exception const& ae){ + BOOST_CHECK( + boost::archive::archive_exception::array_size_too_short + == ae.code + ); + exception_invoked = true; + } + BOOST_CATCH_END + BOOST_CHECK(exception_invoked); + } + is.close(); + } + std::remove(testfile); + return EXIT_SUCCESS; +} + +int test_main( int /* argc */, char* /* argv */[] ){ + int res; + + // native array + res = test_native_array<A>(); + if (res != EXIT_SUCCESS) + return EXIT_FAILURE; + // test an int array for which optimized versions should be available + res = test_native_array<int>(); + if (res != EXIT_SUCCESS) + return EXIT_FAILURE; + + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_new_operator.cpp b/src/boost/libs/serialization/test/test_new_operator.cpp new file mode 100644 index 00000000..b6931216 --- /dev/null +++ b/src/boost/libs/serialization/test/test_new_operator.cpp @@ -0,0 +1,154 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_new_operator.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <cstddef> // NULL +#include <cstdio> // remove +#include <fstream> +#include <new> + +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include <boost/serialization/access.hpp> + +#include "test_tools.hpp" + +#include "A.hpp" +#include "A.ipp" + +class ANew : public A { + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive & ar, const unsigned /*file_version*/){ + ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(A); + } +public: + static unsigned int m_new_calls; + static unsigned int m_delete_calls; + // implement class specific new/delete in terms standard + // implementation - we're testing serialization + // not "new" here. + static void * operator new(size_t s){ + ++m_new_calls; + return ::operator new(s); + } + static void operator delete(void *p, std::size_t){ + ++m_delete_calls; + ::operator delete(p); + } +}; +unsigned int ANew::m_new_calls = 0; +unsigned int ANew::m_delete_calls = 0; + +class ANew1 : public A { + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive & ar, const unsigned /*file_version*/){ + ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(A); + } +public: + static unsigned int m_new_calls; + static unsigned int m_delete_calls; + // implement class specific new/delete in terms standard + // implementation - we're testing serialization + // not "new" here. + static void * operator new(size_t s){ + ++m_new_calls; + return ::operator new(s); + } + static void operator delete(void *p){ + ++m_delete_calls; + ::operator delete(p); + } +}; +unsigned int ANew1::m_new_calls = 0; +unsigned int ANew1::m_delete_calls = 0; + + +class ANew2 : public A { + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive & ar, const unsigned /*file_version*/){ + ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(A); + } +public: + static unsigned int m_new_calls; + static unsigned int m_delete_calls; + // implement class specific new/delete in terms standard + // implementation - we're testing serialization + // not "new" here. + static void * operator new(size_t s){ + ++m_new_calls; + return ::operator new(s); + } +}; +unsigned int ANew2::m_new_calls = 0; +unsigned int ANew2::m_delete_calls = 0; + +template<typename T> +int test(){ + const char * testfile = boost::archive::tmpnam(NULL); + + BOOST_REQUIRE(NULL != testfile); + + + T *ta = new T(); + + BOOST_CHECK(1 == T::m_new_calls); + BOOST_CHECK(0 == T::m_delete_calls); + + T *ta1 = NULL; + + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("ta", ta); + } + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("ta", ta1); + } + BOOST_CHECK(ta != ta1); + BOOST_CHECK(*ta == *ta1); + + BOOST_CHECK(2 == T::m_new_calls); + BOOST_CHECK(0 == T::m_delete_calls); + + std::remove(testfile); + + delete ta; + delete ta1; + + BOOST_CHECK(2 == T::m_new_calls); + BOOST_CHECK(2 == T::m_delete_calls); + + return EXIT_SUCCESS; +} +int test_main( int /* argc */, char* /* argv */[] ){ + if(EXIT_SUCCESS != test<ANew>()) + return EXIT_FAILURE; + if(EXIT_SUCCESS != test<ANew1>()) + return EXIT_FAILURE; + // Note the following test fails. To see why this is, look into the file + // iserializer line # 247. Feel free to send a patch to detect the absense + // of a class specific delete. + /* + if(EXIT_SUCCESS != test<ANew2>()) + return EXIT_FAILURE; + */ + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_no_rtti.cpp b/src/boost/libs/serialization/test/test_no_rtti.cpp new file mode 100644 index 00000000..48e17da2 --- /dev/null +++ b/src/boost/libs/serialization/test/test_no_rtti.cpp @@ -0,0 +1,166 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_no_rtti.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// note: this program tests the inter-operability of different +// extended typeinfo systems. In this example, one class is +// identified using the default RTTI while the other uses a custom +// system based on the export key. +// +// As this program uses RTTI for one of the types, the test will fail +// on a system for which RTTI is not enabled or not existent. + +#include <cstddef> +#include <fstream> +#include <iostream> + +#include <boost/config.hpp> +#include <cstdio> // remove +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include <boost/serialization/type_info_implementation.hpp> +#include <boost/serialization/export.hpp> +#include <boost/serialization/nvp.hpp> + +#include "test_tools.hpp" + +#include <boost/archive/polymorphic_oarchive.hpp> +#include <boost/archive/polymorphic_iarchive.hpp> + +#include "polymorphic_base.hpp" + +#include "polymorphic_derived1.hpp" + +#include "polymorphic_derived2.hpp" + +// save derived polymorphic class +void save_derived(const char *testfile) +{ + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa_implementation(os, TEST_ARCHIVE_FLAGS); + boost::archive::polymorphic_oarchive & oa_interface = oa_implementation; + + polymorphic_derived1 *rd1 = new polymorphic_derived1; + polymorphic_derived2 *rd2 = new polymorphic_derived2; + + std::cout << "saving polymorphic_derived1 (no_rtti)\n"; + oa_interface << BOOST_SERIALIZATION_NVP(rd1); + + std::cout << "saving polymorphic_derived2\n"; + oa_interface << BOOST_SERIALIZATION_NVP(rd2); + + const polymorphic_base *rb1 = rd1; + polymorphic_base *rb2 = rd2; + std::cout << "saving polymorphic_derived1 (no_rtti) through base (rtti)\n"; + oa_interface << BOOST_SERIALIZATION_NVP(rb1); + std::cout << "saving polymorphic_derived2 through base\n"; + oa_interface << BOOST_SERIALIZATION_NVP(rb2); + + delete rd1; + delete rd2; +} + +void load_derived(const char *testfile) +{ + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia_implementation(is, TEST_ARCHIVE_FLAGS); + boost::archive::polymorphic_iarchive & ia_interface = ia_implementation; + + polymorphic_derived1 *rd1 = NULL; + polymorphic_derived2 *rd2 = NULL; + + std::cout << "loading polymorphic_derived1 (no_rtti)\n"; + ia_interface >> BOOST_SERIALIZATION_NVP(rd1); + BOOST_CHECK_MESSAGE( + boost::serialization::type_info_implementation< + polymorphic_derived1 + >::type::get_const_instance() + == + * boost::serialization::type_info_implementation< + polymorphic_derived1 + >::type::get_const_instance().get_derived_extended_type_info(*rd1) + , + "restored pointer d1 not of correct type" + ); + + std::cout << "loading polymorphic_derived2\n"; + ia_interface >> BOOST_SERIALIZATION_NVP(rd2); + BOOST_CHECK_MESSAGE( + boost::serialization::type_info_implementation< + polymorphic_derived2 + >::type::get_const_instance() + == + * boost::serialization::type_info_implementation< + polymorphic_derived2 + >::type::get_const_instance().get_derived_extended_type_info(*rd2) + , + "restored pointer d2 not of correct type" + ); + polymorphic_base *rb1 = NULL; + polymorphic_base *rb2 = NULL; + + // the above opereration registers the derived classes as a side + // effect. Hence, instances can now be correctly serialized through + // a base class pointer. + std::cout << "loading polymorphic_derived1 (no_rtti) through base (no_rtti)\n"; + ia_interface >> BOOST_SERIALIZATION_NVP(rb1); + + BOOST_CHECK_MESSAGE( + rb1 == dynamic_cast<polymorphic_base *>(rd1), + "serialized pointers not correctly restored" + ); + + BOOST_CHECK_MESSAGE( + boost::serialization::type_info_implementation< + polymorphic_derived1 + >::type::get_const_instance() + == + * boost::serialization::type_info_implementation< + polymorphic_base + >::type::get_const_instance().get_derived_extended_type_info(*rb1) + , + "restored pointer b1 not of correct type" + ); + std::cout << "loading polymorphic_derived2 through base (no_rtti)\n"; + ia_interface >> BOOST_SERIALIZATION_NVP(rb2); + + BOOST_CHECK_MESSAGE( + rb2 == dynamic_cast<polymorphic_base *>(rd2), + "serialized pointers not correctly restored" + ); + BOOST_CHECK_MESSAGE( + boost::serialization::type_info_implementation< + polymorphic_derived2 + >::type::get_const_instance() + == + * boost::serialization::type_info_implementation< + polymorphic_base + >::type::get_const_instance().get_derived_extended_type_info(*rb2) + , + "restored pointer b2 not of correct type" + ); + delete rb1; + delete rb2; +} + +int +test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + save_derived(testfile); + load_derived(testfile); + std::remove(testfile); + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_non_default_ctor.cpp b/src/boost/libs/serialization/test/test_non_default_ctor.cpp new file mode 100644 index 00000000..9a656f18 --- /dev/null +++ b/src/boost/libs/serialization/test/test_non_default_ctor.cpp @@ -0,0 +1,198 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_non_default_ctor.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +// this tests: +// a) non-intrusive method of implementing serialization +// b) usage of a non-default constructor + +#include <cstddef> // NULL +#include <cstdio> // remove() +#include <fstream> +#include <cstdlib> // for rand() +#include <boost/config.hpp> +#include <boost/detail/workaround.hpp> +#include <boost/limits.hpp> +#include <boost/math/special_functions/next.hpp> + +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::rand; + using ::remove; + #if BOOST_WORKAROUND(BOOST_MSVC, >= 1400) && !defined(UNDER_CE) + using ::numeric_limits; + #endif +} +#endif + +#include <boost/archive/archive_exception.hpp> +#include "test_tools.hpp" + +/////////////////////////////////////////////////////// +// simple class test - using non-intrusive syntax +// illustrates the usage of the non-intrusve syntax +class A +{ + friend class boost::serialization::access; + + // note const values can only be initialized with a non + // non-default constructor + const int i; + + signed char s; + unsigned char t; + signed int u; + unsigned int v; + float w; + double x; + bool operator==(const A & rhs) const; + bool operator<(const A & rhs) const; + + template<class Archive> + void serialize(Archive & ar,const unsigned int /* file_version */){ + ar & BOOST_SERIALIZATION_NVP(s); + ar & BOOST_SERIALIZATION_NVP(t); + ar & BOOST_SERIALIZATION_NVP(u); + ar & BOOST_SERIALIZATION_NVP(v); + ar & BOOST_SERIALIZATION_NVP(w); + ar & BOOST_SERIALIZATION_NVP(x); + } + A(const A & rhs); + A & operator=(const A & rhs); +public: + static int count; + const int & get_i() const { + return i; + } + A(int i_); + ~A(); +}; + +int A::count = 0; + +A::A(int i_) : + i(i_), + s(static_cast<signed char>(0xff & std::rand())), + t(static_cast<signed char>(0xff & std::rand())), + u(std::rand()), + v(std::rand()), + w((float)std::rand() / std::rand()), + x((double)std::rand() / std::rand()) +{ + ++count; +} + +A::~A(){ + --count; +} + +bool A::operator==(const A &rhs) const +{ + return + s == rhs.s + && t == rhs.t + && u == rhs.u + && v == rhs.v + && std::abs( boost::math::float_distance(w, rhs.w)) < 2 + && std::abs( boost::math::float_distance(x, rhs.x)) < 2 + ; +} + +bool A::operator<(const A &rhs) const +{ + if(! (s == rhs.s) ) + return s < rhs.s; + if(! (t == rhs.t) ) + return t < rhs.t; + if(! (u == rhs.u) ) + return t < rhs.u; + if(! (v == rhs.v) ) + return t < rhs.v; + if(std::abs( boost::math::float_distance(w, rhs.w)) > 1) + return false; + if(std::abs( boost::math::float_distance(x, rhs.x)) > 1) + return false; + return false; +} + +namespace boost { +namespace serialization { + +template<class Archive> +inline void save_construct_data( + Archive & ar, + const A * a, + const unsigned int /* file_version */ +){ + // variable used for construction + ar << boost::serialization::make_nvp("i", a->get_i()); +} + +template<class Archive> +inline void load_construct_data( + Archive & ar, + A * a, + const unsigned int /* file_version */ +){ + int i; + ar >> boost::serialization::make_nvp("i", i); + ::new(a)A(i); +} + +} // serialization +} // namespace boost + +void save(const char * testfile){ + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + A a(2); + + oa << BOOST_SERIALIZATION_NVP(a); + + // save a copy pointer to this item + A *pa1 = &a; + oa << BOOST_SERIALIZATION_NVP(pa1); + + // save pointer to a new object + A *pa2 = new A(4); + oa << BOOST_SERIALIZATION_NVP(pa2); + + delete pa2; +} +void load(const char * testfile){ + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + + A a(4); + ia >> BOOST_SERIALIZATION_NVP(a); + + A *pa1; + ia >> BOOST_SERIALIZATION_NVP(pa1); + BOOST_CHECK_MESSAGE(pa1 == &a, "Copy of pointer not correctly restored"); + + A *pa2; + ia >> BOOST_SERIALIZATION_NVP(pa2); + BOOST_CHECK_MESSAGE(pa2 != &a, "Pointer not correctly restored"); + + delete pa2; +} + +int +test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + save(testfile); + load(testfile); + BOOST_CHECK(0 == A::count); + std::remove(testfile); + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_non_default_ctor2.cpp b/src/boost/libs/serialization/test/test_non_default_ctor2.cpp new file mode 100644 index 00000000..392bb52a --- /dev/null +++ b/src/boost/libs/serialization/test/test_non_default_ctor2.cpp @@ -0,0 +1,144 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_non_default_ctor2.cpp + +// (C) Copyright 2002 Martin Ecker. +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +// this tests complex usage of non-default constructor. Specifically +// the case where a constructor serializes a pointer member. + +#include <fstream> + +#include <boost/config.hpp> + +#include "test_tools.hpp" + +class IntValueHolder +{ +public: + IntValueHolder() + : value(0) + {} + + IntValueHolder(int newvalue) + : value(newvalue) + {} + + int GetValue() const { return value; } + +private: + int value; + + friend class boost::serialization::access; + + template <class ArchiveT> + void serialize(ArchiveT& ar, const unsigned int /* file_version */) + { + ar & BOOST_SERIALIZATION_NVP(value); + } +}; + +class FloatValueHolder +{ +public: + FloatValueHolder() + : value(0) + {} + + FloatValueHolder(float newvalue) + : value(newvalue) + {} + + float GetValue() const { return value; } + +private: + float value; + + friend class boost::serialization::access; + + template <class ArchiveT> + void serialize(ArchiveT& ar, const unsigned int /* file_version */) + { + ar & BOOST_SERIALIZATION_NVP(value); + } +}; + +class A +{ +public: + A(const IntValueHolder& initialValue) + : value(initialValue), floatValue(new FloatValueHolder(10.0f)) + {} + + ~A() + { + delete floatValue; + } + + IntValueHolder value; + FloatValueHolder* floatValue; + +private: + friend class boost::serialization::access; + + template <class ArchiveT> + void serialize(ArchiveT& ar, const unsigned int /* file_version */) + { + ar & BOOST_SERIALIZATION_NVP(floatValue); + } +}; + +namespace boost { +namespace serialization { + +template <class ArchiveT> +void save_construct_data( + ArchiveT& archive, + const A* p, + const unsigned int /*version*/ +){ + archive & boost::serialization::make_nvp("initialValue", p->value); +} + +template <class ArchiveT> +void load_construct_data( + ArchiveT& archive, + A* p, + const unsigned int /*version*/ +){ + IntValueHolder initialValue; + archive & boost::serialization::make_nvp("initialValue", initialValue); + + ::new (p) A(initialValue); +} + +} // serialization +} // namespace boost + +int test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + A* a = new A(5); + + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << BOOST_SERIALIZATION_NVP(a); + } + + A* a_new; + + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> BOOST_SERIALIZATION_NVP(a_new); + } + delete a; + delete a_new; + return EXIT_SUCCESS; +} diff --git a/src/boost/libs/serialization/test/test_non_intrusive.cpp b/src/boost/libs/serialization/test/test_non_intrusive.cpp new file mode 100644 index 00000000..79dcdfb8 --- /dev/null +++ b/src/boost/libs/serialization/test/test_non_intrusive.cpp @@ -0,0 +1,174 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_non_intrursive.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +// this tests: +// a) non-intrusive method of implementing serialization +// b) usage of a non-default constructor + +#include <fstream> +#include <cstdlib> // for rand() +#include <cstdio> // remove +#include <boost/config.hpp> +#include <boost/detail/workaround.hpp> +#include <boost/limits.hpp> +#include <boost/math/special_functions/next.hpp> + +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::rand; + using ::remove; + #if BOOST_WORKAROUND(BOOST_MSVC, >= 1400) && !defined(UNDER_CE) + using ::numeric_limits; + #endif +} +#endif + +#include <boost/archive/archive_exception.hpp> +#include "test_tools.hpp" + +/////////////////////////////////////////////////////// +// simple class test - using non-intrusive syntax +// illustrates the usage of the non-intrusve syntax +class A +{ +public: + signed char s; + unsigned char t; + signed int u; + unsigned int v; + float w; + double x; + A(); + bool operator==(const A & rhs) const; + bool operator<(const A & rhs) const; +}; + +A::A() : + s(static_cast<signed char>(0xff & std::rand())), + t(static_cast<signed char>(0xff & std::rand())), + u(std::rand()), + v(std::rand()), + w((float)std::rand() / std::rand()), + x((double)std::rand() / std::rand()) +{ +} + +bool A::operator==(const A &rhs) const +{ + return + s == rhs.s + && t == rhs.t + && u == rhs.u + && v == rhs.v + && std::abs( boost::math::float_distance(w, rhs.w)) < 2 + && std::abs( boost::math::float_distance(x, rhs.x)) < 2 + ; +} + +bool A::operator<(const A &rhs) const +{ + if(! (s == rhs.s) ) + return s < rhs.s; + if(! (t == rhs.t) ) + return t < rhs.t; + if(! (u == rhs.u) ) + return t < rhs.u; + if(! (v == rhs.v) ) + return t < rhs.v; + if(std::abs( boost::math::float_distance(w, rhs.w)) > 1) + return false; + if(std::abs( boost::math::float_distance(x, rhs.x)) > 1) + return false; + return false; +} + +// note the following: + +// function specializations must be defined in the appropriate +// namespace - boost::serialization +namespace boost { +namespace serialization { + +// This first set of overrides should work with all compilers. + +// The last argument is int while the default versions +// defined in serialization.hpp have long as the last argument. +// This is part of the work around for compilers that don't +// support correct function template ordering. These functions +// are always called with 0 (i.e. an int) as the last argument. +// Our specialized versions also have int as the last argument +// while the default versions have a long as the last argument. +// This makes our specialized versions a better match than the +// default ones as no argument conversion is required to make a match +template<class Archive> +void serialize( + Archive & ar, + A & a, + const unsigned int /* file_version */ +){ + ar & boost::serialization::make_nvp("s", a.s); + ar & boost::serialization::make_nvp("t", a.t); + ar & boost::serialization::make_nvp("u", a.u); + ar & boost::serialization::make_nvp("v", a.v); + ar & boost::serialization::make_nvp("w", a.w); + ar & boost::serialization::make_nvp("x", a.x); +} + +} // serialization +} // namespace boost + +void save(const char * testfile){ + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + A a; + + oa << BOOST_SERIALIZATION_NVP(a); + + // save a copy pointer to this item + A *pa1 = &a; + oa << BOOST_SERIALIZATION_NVP(pa1); + + // save pointer to a new object + A *pa2 = new A(); + oa << BOOST_SERIALIZATION_NVP(pa2); + + delete pa2; +} + +void load(const char * testfile){ + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + + A a; + ia >> BOOST_SERIALIZATION_NVP(a); + + A *pa1; + ia >> BOOST_SERIALIZATION_NVP(pa1); + BOOST_CHECK_MESSAGE(pa1 == &a, "Copy of pointer not correctly restored"); + + A *pa2; + ia >> BOOST_SERIALIZATION_NVP(pa2); + BOOST_CHECK_MESSAGE(pa2 != &a, "Pointer not correctly restored"); + + delete pa2; +} + +int +test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + save(testfile); + load(testfile); + std::remove(testfile); + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_not_serializable.cpp b/src/boost/libs/serialization/test/test_not_serializable.cpp new file mode 100644 index 00000000..4833512d --- /dev/null +++ b/src/boost/libs/serialization/test/test_not_serializable.cpp @@ -0,0 +1,47 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_non_serializable.cpp: test implementation level trait + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// test implementation level "not_serializable" +// should fail compilation + +#include <fstream> + +#include "test_tools.hpp" +#include <boost/serialization/level.hpp> +#include <boost/serialization/nvp.hpp> + +class A +{ +}; + +BOOST_CLASS_IMPLEMENTATION(A, boost::serialization::not_serializable) + +void out(A & a) +{ + test_ostream os("testfile", TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << BOOST_SERIALIZATION_NVP(a); +} + +void in(A & a) +{ + test_istream is("testfile", TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> BOOST_SERIALIZATION_NVP(a); +} + +int +test_main( int /* argc */, char* /* argv */[] ) +{ + A a; + out(a); + in(a); + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_null_ptr.cpp b/src/boost/libs/serialization/test/test_null_ptr.cpp new file mode 100644 index 00000000..e52631a8 --- /dev/null +++ b/src/boost/libs/serialization/test/test_null_ptr.cpp @@ -0,0 +1,89 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_null_ptr.cpp: test implementation level trait + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <cstddef> // NULL +#include <cstdio> // remove +#include <fstream> + +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include "test_tools.hpp" +#include <boost/serialization/base_object.hpp> + +class polymorphic_base +{ + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive & /* ar */, const unsigned int /* file_version */){ + } +public: + virtual ~polymorphic_base(){}; +}; + +class polymorphic_derived1 : public polymorphic_base +{ + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive &ar, const unsigned int /* file_version */){ + ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(polymorphic_base); + } +}; + +// save unregistered polymorphic classes +void save(const char *testfile) +{ + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + + polymorphic_base *rb1 = NULL; + polymorphic_derived1 *rd1 = NULL; + + oa << BOOST_SERIALIZATION_NVP(rb1); + oa << BOOST_SERIALIZATION_NVP(rd1); +} + +// load unregistered polymorphic classes +void load(const char *testfile) +{ + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + + polymorphic_derived1 dummy; + + polymorphic_base *rb1 = & dummy; + polymorphic_derived1 *rd1 = & dummy; + + ia >> BOOST_SERIALIZATION_NVP(rb1); + BOOST_CHECK_MESSAGE(NULL == rb1, "Null pointer not restored"); + + ia >> BOOST_SERIALIZATION_NVP(rd1); + BOOST_CHECK_MESSAGE(NULL == rd1, "Null pointer not restored"); + + delete rb1; + delete rd1; +} + +int +test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + save(testfile); + load(testfile); + std::remove(testfile); + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_nvp.cpp b/src/boost/libs/serialization/test/test_nvp.cpp new file mode 100644 index 00000000..cd546e01 --- /dev/null +++ b/src/boost/libs/serialization/test/test_nvp.cpp @@ -0,0 +1,68 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_nvp.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <cstddef> // NULL +#include <cstdio> // remove +#include <fstream> + +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include "test_tools.hpp" + +#include <boost/serialization/nvp.hpp> + +#include "B.hpp" +#include "A.ipp" + +int +test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + B b, b1; + + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << BOOST_SERIALIZATION_NVP(b); + } + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> BOOST_SERIALIZATION_NVP(b1); + } + BOOST_CHECK(b == b1); + + B *bptr = &b; + B *bptr1; + + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << BOOST_SERIALIZATION_NVP(bptr); + } + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> BOOST_SERIALIZATION_NVP(bptr1); + } + BOOST_CHECK(b == *bptr1); + + std::remove(testfile); + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_object.cpp b/src/boost/libs/serialization/test/test_object.cpp new file mode 100644 index 00000000..acf44e8c --- /dev/null +++ b/src/boost/libs/serialization/test/test_object.cpp @@ -0,0 +1,70 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_object.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// test implementation level "object_serializable" +// should pass compilation and execution + +#include <cstddef> // NULL +#include <cstdio> // remove +#include <fstream> + +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include "test_tools.hpp" + +#include <boost/serialization/level.hpp> +#include <boost/serialization/nvp.hpp> + +class A +{ + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive & /* ar */, const unsigned int /* file_version */){ + } +}; + +BOOST_CLASS_IMPLEMENTATION(A, boost::serialization::object_serializable) + +// note: version can be assigned only to objects whose implementation +// level is object_class_info. So, doing the following will result in +// a static assertion +// BOOST_CLASS_VERSION(A, 2); + +void out(const char *testfile, A & a) +{ + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << BOOST_SERIALIZATION_NVP(a); +} + +void in(const char *testfile, A & a) +{ + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> BOOST_SERIALIZATION_NVP(a); +} + +int +test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + A a; + out(testfile, a); + in(testfile, a); + std::remove(testfile); + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_optional.cpp b/src/boost/libs/serialization/test/test_optional.cpp new file mode 100644 index 00000000..330b2d7e --- /dev/null +++ b/src/boost/libs/serialization/test/test_optional.cpp @@ -0,0 +1,96 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_optional.cpp + +// (C) Copyright 2004 Pavel Vozenilek +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <cstddef> // NULL +#include <cstdio> // remove +#include <fstream> + +#include <boost/config.hpp> + +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include <boost/archive/archive_exception.hpp> +#include "test_tools.hpp" + +#include <boost/serialization/optional.hpp> +#include <boost/serialization/string.hpp> + +struct A { + int m_x; + template<class Archive> + void serialize(Archive & ar, const unsigned int /* version */){ + ar & boost::serialization::make_nvp("x", m_x); + }; + bool operator==(const A & rhs) const { + return m_x == rhs.m_x; + } + // note that default constructor is not trivial + A() : + m_x(0) + {} + A(int x) : + m_x(x) + {} +}; + +int test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + const boost::optional<int> aoptional1; + const boost::optional<int> aoptional2(123); + const boost::optional<A> aoptional3; + A a(1); + const boost::optional<A> aoptional4(a); + const boost::optional<A *> aoptional5; + const boost::optional<A *> aoptional6(& a); + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("aoptional1",aoptional1); + oa << boost::serialization::make_nvp("aoptional2",aoptional2); + oa << boost::serialization::make_nvp("aoptional3",aoptional3); + oa << boost::serialization::make_nvp("aoptional4",aoptional4); + oa << boost::serialization::make_nvp("aoptional5",aoptional5); + oa << boost::serialization::make_nvp("aoptional6",aoptional6); + } + boost::optional<int> aoptional1a(999); + boost::optional<int> aoptional2a; + boost::optional<A> aoptional3a; + boost::optional<A> aoptional4a; + boost::optional<A *> aoptional5a; + boost::optional<A *> aoptional6a; + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("aoptional1",aoptional1a); + ia >> boost::serialization::make_nvp("aoptional2",aoptional2a); + ia >> boost::serialization::make_nvp("aoptional3",aoptional3a); + ia >> boost::serialization::make_nvp("aoptional4",aoptional4a); + ia >> boost::serialization::make_nvp("aoptional5",aoptional5a); + ia >> boost::serialization::make_nvp("aoptional6",aoptional6a); + } + BOOST_CHECK(aoptional1 == aoptional1a); + BOOST_CHECK(aoptional2 == aoptional2a); + BOOST_CHECK(aoptional3 == aoptional3a); + BOOST_CHECK(aoptional4.get() == aoptional4a.get()); + BOOST_CHECK(aoptional5 == aoptional5a); + BOOST_CHECK(*aoptional6.get() == *aoptional6a.get()); + + std::remove(testfile); + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_p_helper.cpp b/src/boost/libs/serialization/test/test_p_helper.cpp new file mode 100644 index 00000000..0d68588e --- /dev/null +++ b/src/boost/libs/serialization/test/test_p_helper.cpp @@ -0,0 +1,160 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_polymorphic.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <cstddef> // NULL +#include <cstdio> // remove +#include <fstream> + +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +// the following is to ensure that when one of the libraries changes +// BJAM rebuilds and relinks the test. +/* +#include "polymorphic_text_archive.hpp" +#include "polymorphic_text_warchive.hpp" +#include "polymorphic_binary_archive.hpp" +#include "polymorphic_xml_archive.hpp" +#include "polymorphic_xml_warchive.hpp" +*/ + +#include <string> +#include <vector> + +#include "test_tools.hpp" +#include <boost/lexical_cast.hpp> +#include <boost/serialization/split_free.hpp> +#include <boost/serialization/vector.hpp> +#include <boost/serialization/nvp.hpp> +// this test uses a special string (my_string) whose contents are shared +// and hence saved in the archive only once. We need a helper in order +// to convert my_string into a serializable type + +class my_string:public std::string +{ + typedef std::string super; + +public: + my_string(){} + my_string(const super & str): super(str){} + my_string & operator=(const super& rhs) { + super::operator=(rhs); + return *this; + } +}; + +struct my_string_helper +{ + typedef std::vector<my_string> table; + table m_t; +}; + +BOOST_SERIALIZATION_SPLIT_FREE(my_string) + +namespace boost { +namespace serialization { + +template<class Archive> +void save(Archive & ar, const my_string & str, const unsigned int /* version */) +{ + void (* const idx)(Archive &, const my_string &, const unsigned int) = & save; + void * const id = reinterpret_cast<void * const>(idx); + my_string_helper & msh = ar.template get_helper<my_string_helper>(id); + + my_string_helper::table t = msh.m_t; + my_string_helper::table::iterator it = std::find(t.begin(), t.end(), str); + if(it == t.end()){ + my_string_helper::table::size_type s = t.size(); + ar << make_nvp("index", s); + t.push_back(str); + ar << make_nvp("string", static_cast<const std::string &>(str)); + } + else{ + my_string_helper::table::size_type s = it - t.begin(); + ar << make_nvp("index", s); + } +} + +template<class Archive> +void load(Archive & ar, my_string & str, const unsigned int /* version */) +{ + void (* const idx)(Archive &, my_string &, const unsigned int) = & load; + void * const id = reinterpret_cast<void * const>(idx); + my_string_helper & msh = ar.template get_helper<my_string_helper>(id); + + my_string_helper::table t = msh.m_t; + + my_string_helper::table::size_type s; + ar >> make_nvp("index", s); + t.reserve(s); + if(s >= t.size()){ + std::string tmp; + ar >> make_nvp("string", tmp); + str = tmp; + t.push_back(str); + } + else{ + str = t[s]; + } +} + +} // namespace serialization +} // namespace boost +#include <boost/archive/polymorphic_oarchive.hpp> +#include <boost/archive/polymorphic_iarchive.hpp> + +int test_main(int /* argc */, char * /* argv */ []) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + std::vector<my_string> v1; + for(int i=0; i<1000; ++i){ + v1.push_back(my_string(boost::lexical_cast<std::string>(i % 100))); + } + + // test using using polymorphic implementation. + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa_implementation(os, TEST_ARCHIVE_FLAGS); + oa_implementation << boost::serialization::make_nvp("vector", v1); + } + { + std::vector<my_string> v2; + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia_implementation(is, TEST_ARCHIVE_FLAGS); + ia_implementation >> boost::serialization::make_nvp("vector", v2); + BOOST_CHECK(v1 == v2); + } + std::remove(testfile); + + // test using using polymorphic interface. + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa_implementation(os, TEST_ARCHIVE_FLAGS); + boost::archive::polymorphic_oarchive & oa_interface = oa_implementation; + oa_interface << boost::serialization::make_nvp("vector", v1); + } + { + std::vector<my_string> v2; + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia_implementation(is, TEST_ARCHIVE_FLAGS); + boost::archive::polymorphic_iarchive & ia_interface = ia_implementation; + ia_interface >> boost::serialization::make_nvp("vector", v2); + BOOST_CHECK(v1 == v2); + } + std::remove(testfile); + std::remove(testfile); + return EXIT_SUCCESS; +} diff --git a/src/boost/libs/serialization/test/test_pimpl.cpp b/src/boost/libs/serialization/test/test_pimpl.cpp new file mode 100644 index 00000000..b87a8cf2 --- /dev/null +++ b/src/boost/libs/serialization/test/test_pimpl.cpp @@ -0,0 +1,48 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_pimpl.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <boost/compatibility/cpp_c_headers/cstdio> // for tmpnam + +#include <fstream> +#include <boost/serialization/nvp.hpp> + +#include "test_tools.hpp" + +class B; + +class A { + friend boost::serialization::access; + B *pimpl; + template<class Archive> + void serialize(Archive & ar, const unsigned int file_version); +}; + +int test_main( int argc, char* argv[] ) +{ + char testfile[TMP_MAX]; + std::tmpnam(testfile); +// BOOST_REQUIRE(NULL != testfile); + + A a, a1; + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os); + oa << BOOST_SERIALIZATION_NVP(a); + } + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is); + BOOST_SERIALIZATION_NVP(a1); + } +// BOOST_CHECK(a != a1); + return 0; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_polymorphic.cpp b/src/boost/libs/serialization/test/test_polymorphic.cpp new file mode 100644 index 00000000..33957e1c --- /dev/null +++ b/src/boost/libs/serialization/test/test_polymorphic.cpp @@ -0,0 +1,94 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_polymorphic.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <cstddef> // NULL +#include <cstdio> // remove +#include <fstream> + +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +// the following is to ensure that when one of the libraries changes +// BJAM rebuilds and relinks the test. +/* +#include "polymorphic_text_archive.hpp" +#include "polymorphic_text_warchive.hpp" +#include "polymorphic_binary_archive.hpp" +#include "polymorphic_xml_archive.hpp" +#include "polymorphic_xml_warchive.hpp" +*/ + +#include "test_tools.hpp" + +#include <boost/archive/polymorphic_oarchive.hpp> +#include <boost/archive/polymorphic_iarchive.hpp> + +#include <boost/serialization/nvp.hpp> +#include "test_polymorphic_A.hpp" + +int test_main(int /* argc */, char * /* argv */ []) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + const data d; + data d1; + // test using using polymorphic interface + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa_implementation(os, TEST_ARCHIVE_FLAGS); + boost::archive::polymorphic_oarchive & oa_interface = oa_implementation; + oa_interface << BOOST_SERIALIZATION_NVP(d); + } + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia_implementation(is, TEST_ARCHIVE_FLAGS); + boost::archive::polymorphic_iarchive & ia_interface = ia_implementation; + ia_interface >> BOOST_SERIALIZATION_NVP(d1); + } + BOOST_CHECK(d == d1); + std::remove(testfile); + + // test using using polymorphic implementation. + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa_implementation(os, TEST_ARCHIVE_FLAGS); + oa_implementation << BOOST_SERIALIZATION_NVP(d); + } + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia_implementation(is, TEST_ARCHIVE_FLAGS); + ia_implementation >> BOOST_SERIALIZATION_NVP(d1); + } + BOOST_CHECK(d == d1); + std::remove(testfile); + + // test using using polymorphic interface. + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + boost::archive::polymorphic_oarchive * oa_implementation + = new test_oarchive(os, TEST_ARCHIVE_FLAGS); + *oa_implementation << BOOST_SERIALIZATION_NVP(d); + delete oa_implementation; + } + { + test_istream is(testfile, TEST_STREAM_FLAGS); + boost::archive::polymorphic_iarchive * ia_implementation + = new test_iarchive(is, TEST_ARCHIVE_FLAGS); + *ia_implementation >> BOOST_SERIALIZATION_NVP(d1); + delete ia_implementation; + } + BOOST_CHECK(d == d1); + std::remove(testfile); + return EXIT_SUCCESS; +} diff --git a/src/boost/libs/serialization/test/test_polymorphic2.cpp b/src/boost/libs/serialization/test/test_polymorphic2.cpp new file mode 100644 index 00000000..52ee3082 --- /dev/null +++ b/src/boost/libs/serialization/test/test_polymorphic2.cpp @@ -0,0 +1,40 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_polymorphic2.cpp + +// (C) Copyright 2009 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution +#include <fstream> + +#include "test_tools.hpp" + +#include "test_polymorphic2.hpp" + +int test_main(int /*argc*/, char* /*argv*/[]) +{ + A *a = new B(); + a->i = 3; + + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa_implementation(os, TEST_ARCHIVE_FLAGS); + boost::archive::polymorphic_oarchive & opa = oa_implementation; + opa << BOOST_SERIALIZATION_NVP(a); + } + A *loaded = 0; + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia_implementation(is, TEST_ARCHIVE_FLAGS); + boost::archive::polymorphic_iarchive & ipa = ia_implementation; + ipa >> BOOST_SERIALIZATION_NVP(loaded); + } + BOOST_CHECK(a->i == loaded->i); + delete a; + delete loaded; + return EXIT_SUCCESS; +} diff --git a/src/boost/libs/serialization/test/test_polymorphic2.hpp b/src/boost/libs/serialization/test/test_polymorphic2.hpp new file mode 100644 index 00000000..a2cd4f12 --- /dev/null +++ b/src/boost/libs/serialization/test/test_polymorphic2.hpp @@ -0,0 +1,43 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_polymorphic2.hpp + +// (C) Copyright 2009 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution +namespace boost { +namespace archive { + class polymorphic_oarchive; + class polymorphic_iarchive; +} +} + +struct A { +public: + A() {} + virtual ~A() {} + + void serialize( + boost::archive::polymorphic_oarchive &ar, + const unsigned int /*version*/ + ); + void serialize( + boost::archive::polymorphic_iarchive &ar, + const unsigned int /*version*/ + ); + + int i; +}; + +struct B : A { + void serialize( + boost::archive::polymorphic_oarchive &ar, + const unsigned int /*version*/ + ); + void serialize( + boost::archive::polymorphic_iarchive &ar, + const unsigned int /*version*/ + ); +}; diff --git a/src/boost/libs/serialization/test/test_polymorphic2imp.cpp b/src/boost/libs/serialization/test/test_polymorphic2imp.cpp new file mode 100644 index 00000000..e0544e81 --- /dev/null +++ b/src/boost/libs/serialization/test/test_polymorphic2imp.cpp @@ -0,0 +1,44 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_polymorphic2imp.cpp + +// (C) Copyright 2009 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <boost/serialization/export.hpp> +#include <boost/archive/polymorphic_oarchive.hpp> +#include <boost/archive/polymorphic_iarchive.hpp> + +#include "test_polymorphic2.hpp" + +void A::serialize( + boost::archive::polymorphic_oarchive &ar, + const unsigned int /*version*/ +){ + ar & BOOST_SERIALIZATION_NVP(i); +} +void A::serialize( + boost::archive::polymorphic_iarchive &ar, + const unsigned int /*version*/ +){ + ar & BOOST_SERIALIZATION_NVP(i); +} +// note: only the most derived classes need be exported +// BOOST_CLASS_EXPORT(A) + +void B::serialize( + boost::archive::polymorphic_oarchive &ar, + const unsigned int /*version*/ +){ + ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(A); +} +void B::serialize( + boost::archive::polymorphic_iarchive &ar, + const unsigned int /*version*/ +){ + ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(A); +} +BOOST_CLASS_EXPORT(B) diff --git a/src/boost/libs/serialization/test/test_polymorphic_A.cpp b/src/boost/libs/serialization/test/test_polymorphic_A.cpp new file mode 100644 index 00000000..c7c598ca --- /dev/null +++ b/src/boost/libs/serialization/test/test_polymorphic_A.cpp @@ -0,0 +1,58 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_polymorphic_A.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +#include "test_polymorphic_A.hpp" +#include <boost/serialization/nvp.hpp> + +#include "A.hpp" +#include "A.ipp" + +data::data() : + a(new A) +{} +data::~data(){ + delete a; +} + +bool data::operator==(const data & rhs) const { + return * (a) == *(rhs.a); +} + +#if 0 // this method fails with msvc 6.0 and borland +// now we can define the serialization for class A +template<class Archive> +void data::serialize(Archive & ar, const unsigned int /* file_version */){ + ar & BOOST_SERIALIZATION_NVP(a); +} + +// without the explicit instantiations below, the program will +// fail to link for lack of instantiantiation of the above function +// note: the following failed to fix link errors for vc 7.0 ! +#include <boost/archive/polymorphic_oarchive.hpp> + +template void data::serialize<boost::archive::polymorphic_oarchive>( + boost::archive::polymorphic_oarchive & ar, + const unsigned int file_version +); + +#include <boost/archive/polymorphic_iarchive.hpp> + +template void data::serialize<boost::archive::polymorphic_iarchive>( + boost::archive::polymorphic_iarchive & ar, + const unsigned int file_version +); +#endif + +// so use this +void data::serialize(boost::archive::polymorphic_oarchive & ar, const unsigned int /* file_version */){ + ar & BOOST_SERIALIZATION_NVP(a); +} + +void data::serialize(boost::archive::polymorphic_iarchive & ar, const unsigned int /* file_version */){ + ar & BOOST_SERIALIZATION_NVP(a); +} diff --git a/src/boost/libs/serialization/test/test_polymorphic_A.hpp b/src/boost/libs/serialization/test/test_polymorphic_A.hpp new file mode 100644 index 00000000..306d6261 --- /dev/null +++ b/src/boost/libs/serialization/test/test_polymorphic_A.hpp @@ -0,0 +1,30 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_polymorphic_A.hpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// class whose declaration is hidden by a pointer +// #include <boost/serialization/scoped_ptr.hpp> + +#include <boost/archive/polymorphic_oarchive.hpp> +#include <boost/archive/polymorphic_iarchive.hpp> + +class A; + +struct data { + // class a contains a pointer to a "hidden" declaration + // borland scoped_ptr doesn't work !!! + // boost::scoped_ptr<A> a; + A * a; +// template<class Archive> +// void serialize(Archive & ar, const unsigned int file_version); + void serialize(boost::archive::polymorphic_oarchive & ar, const unsigned int file_version); + void serialize(boost::archive::polymorphic_iarchive & ar, const unsigned int file_version); + data(); + ~data(); + bool operator==(const data & rhs) const; +}; + diff --git a/src/boost/libs/serialization/test/test_primitive.cpp b/src/boost/libs/serialization/test/test_primitive.cpp new file mode 100644 index 00000000..d9585458 --- /dev/null +++ b/src/boost/libs/serialization/test/test_primitive.cpp @@ -0,0 +1,66 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_primitive.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// test implementation level "primitive_type" + +#include <cstddef> // NULL +#include <fstream> + +#include <boost/config.hpp> + +#include "test_tools.hpp" + +#include <boost/serialization/level.hpp> +#include <boost/serialization/nvp.hpp> + +struct A +{ + template<class Archive> + void serialize(Archive &ar, const unsigned int /* file_version */){ + // note: should never fail here + BOOST_STATIC_ASSERT(0 == sizeof(Archive)); + } +}; + +std::ostream & operator<<(std::ostream &os, const A & /* a */){ return os;} +std::istream & operator>>(std::istream &is, A & /* a */){return is;} + +#ifndef BOOST_NO_STD_WSTREAMBUF +std::wostream & operator<<(std::wostream &os, const A & /* a */){ return os;} +std::wistream & operator>>(std::wistream &is, A & /* a */){return is;} +#endif + +BOOST_CLASS_IMPLEMENTATION(A, boost::serialization::primitive_type) + +void out(const char *testfile, A & a) +{ + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << BOOST_SERIALIZATION_NVP(a); +} + +void in(const char *testfile, A & a) +{ + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> BOOST_SERIALIZATION_NVP(a); +} + +int +test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + A a; + out(testfile, a); + in(testfile, a); + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_priority_queue.cpp b/src/boost/libs/serialization/test/test_priority_queue.cpp new file mode 100644 index 00000000..bb4c7cfe --- /dev/null +++ b/src/boost/libs/serialization/test/test_priority_queue.cpp @@ -0,0 +1,65 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_priority_queue.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <cstddef> +#include <fstream> + +#include <cstdio> // remove +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include "test_tools.hpp" + +#include <boost/serialization/vector.hpp> +#include <boost/serialization/priority_queue.hpp> + +#include "A.hpp" +#include "A.ipp" + +int test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + // test array of objects + std::priority_queue<A, std::vector<A> > a_priority_queue, a_priority_queue1; + a_priority_queue.push(A()); + a_priority_queue.push(A()); + a_priority_queue.push(A()); + a_priority_queue.push(A()); + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("a_priority_queue",a_priority_queue); + } + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("a_priority_queue",a_priority_queue1); + } + BOOST_CHECK(a_priority_queue.size() == a_priority_queue1.size()); + + for(int i = a_priority_queue.size(); i-- > 0;){ + const A & a1 = a_priority_queue.top(); + const A & a2 = a_priority_queue1.top(); + BOOST_CHECK(a1 == a2); + a_priority_queue.pop(); + a_priority_queue1.pop(); + } + + std::remove(testfile); + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_private_base.cpp b/src/boost/libs/serialization/test/test_private_base.cpp new file mode 100644 index 00000000..38ffefa1 --- /dev/null +++ b/src/boost/libs/serialization/test/test_private_base.cpp @@ -0,0 +1,84 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_private_base.cpp + +// (C) Copyright 2009 Eric Moyer - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +// invoke header for a custom archive test. + +#include <fstream> +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include <boost/serialization/access.hpp> +#include <boost/serialization/base_object.hpp> +#include <boost/serialization/export.hpp> + +#include "test_tools.hpp" + +class Base { + friend class boost::serialization::access; + int m_i; + template<class Archive> + void serialize(Archive & ar, const unsigned int version){ + ar & BOOST_SERIALIZATION_NVP(m_i); + } +protected: + bool equals(const Base &rhs) const { + return m_i == rhs.m_i; + } + Base(int i = 0) : + m_i(i) + {} +public: +}; + +class Derived : private Base { + friend class boost::serialization::access; +private: + Base & base_cast(){ + return static_cast<Base &>(*this); + } + template<class Archive> + void serialize(Archive & ar, const unsigned int version){ + ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(Base); + } +public: + bool operator==(const Derived &rhs) const { + return Base::equals(static_cast<const Base &>(rhs)); + } + Derived(int i = 0) : + Base(i) + {} +}; + +int +test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + Derived a(1), a1(2); + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("a", a); + } + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("a", a1); + } + BOOST_CHECK_EQUAL(a, a1); + std::remove(testfile); + + return 0; +} diff --git a/src/boost/libs/serialization/test/test_private_base2.cpp b/src/boost/libs/serialization/test/test_private_base2.cpp new file mode 100644 index 00000000..19476ee2 --- /dev/null +++ b/src/boost/libs/serialization/test/test_private_base2.cpp @@ -0,0 +1,104 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_private_base.cpp + +// (C) Copyright 2009 Eric Moyer - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +// invoke header for a custom archive test. + +#include <fstream> +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include <boost/serialization/access.hpp> +#include <boost/serialization/base_object.hpp> +#include <boost/serialization/export.hpp> + +#include "test_tools.hpp" + +class Base { + friend class boost::serialization::access; + int m_i; + template<class Archive> + void serialize(Archive & ar, const unsigned int version){ + ar & BOOST_SERIALIZATION_NVP(m_i); + } +protected: + bool equals(const Base &rhs) const { + return m_i == rhs.m_i; + } + Base(int i = 0) : + m_i(i) + {} + virtual ~Base(){}; +public: + virtual bool operator==(const Base &rhs) const { + return false; + }// = 0; +}; + +class Derived : private Base { + friend class boost::serialization::access; +public: + virtual bool operator==(const Derived &rhs) const { + return Base::equals(static_cast<const Base &>(rhs)); + } + Derived(int i = 0) : + Base(i) + {} +}; + +//BOOST_CLASS_EXPORT(Derived) + +int +test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + Derived a(1), a1(2); + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("a", a); + } + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("a", a1); + } + BOOST_CHECK_EQUAL(a, a1); + std::remove(testfile); + + //Base *ta = static_cast<Base *>(&a); + //Base *ta1 = NULL; + + Derived *ta = &a; + Derived *ta1 = NULL; + + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("ta", ta); + } + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("ta", ta1); + } + BOOST_CHECK(ta != ta1); + BOOST_CHECK(*ta == *ta1); + //BOOST_CHECK(*static_cast<Derived *>(ta) == *static_cast<Derived *>(ta1)); + + std::remove(testfile); + + return 0; +} diff --git a/src/boost/libs/serialization/test/test_private_ctor.cpp b/src/boost/libs/serialization/test/test_private_ctor.cpp new file mode 100644 index 00000000..c8bcdb24 --- /dev/null +++ b/src/boost/libs/serialization/test/test_private_ctor.cpp @@ -0,0 +1,66 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_private_ctor.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +#include <sstream> + +#include "test_tools.hpp" + +#include <boost/serialization/vector.hpp> + +#include <boost/archive/text_iarchive.hpp> +#include <boost/archive/text_oarchive.hpp> + +class V { +private: + friend int test_main(int /* argc */, char * /* argv */[]); + friend class boost::serialization::access; + int m_i; + V() : + m_i(0) + {} + template<class Archive> + void serialize(Archive& ar, unsigned /*version*/) + { + ar & m_i; + } +public: + ~V(){} + bool operator==(const V & v) const { + return m_i == v.m_i; + } +}; + +int test_main(int /* argc */, char * /* argv */[]) +{ + std::stringstream ss; + const V v; + { + boost::archive::text_oarchive oa(ss); + oa << v; + } + V v1; + { + boost::archive::text_iarchive ia(ss); + ia >> v1; + } + BOOST_CHECK(v == v1); + + const V *vptr = & v; + { + boost::archive::text_oarchive oa(ss); + oa << vptr; + } + V *vptr1; + { + boost::archive::text_iarchive ia(ss); + ia >> vptr1; + } + BOOST_CHECK(*vptr == *vptr1); + + return EXIT_SUCCESS; +} diff --git a/src/boost/libs/serialization/test/test_queue.cpp b/src/boost/libs/serialization/test/test_queue.cpp new file mode 100644 index 00000000..9fba14b1 --- /dev/null +++ b/src/boost/libs/serialization/test/test_queue.cpp @@ -0,0 +1,56 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_queue.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <cstddef> +#include <fstream> + +#include <cstdio> // remove +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include <boost/archive/archive_exception.hpp> +#include "test_tools.hpp" + +#include <boost/serialization/deque.hpp> +#include <boost/serialization/queue.hpp> + +#include "A.hpp" +#include "A.ipp" + +int test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + // test array of objects + std::queue<A> aqueue, aqueue1; + aqueue.push(A()); + aqueue.push(A()); + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("aqueue",aqueue); + } + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("aqueue",aqueue1); + } + BOOST_CHECK(aqueue == aqueue1); + + std::remove(testfile); + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_recursion.cpp b/src/boost/libs/serialization/test/test_recursion.cpp new file mode 100644 index 00000000..a44f293c --- /dev/null +++ b/src/boost/libs/serialization/test/test_recursion.cpp @@ -0,0 +1,51 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_recurrsion.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <cstddef> // NULL +#include <cstdio> // remove +#include <fstream> + +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include "test_tools.hpp" + +#include "J.hpp" +#include "A.ipp" + +int test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + // test recursive structure + J j, j1; + j.j = &j; + + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << BOOST_SERIALIZATION_NVP(j); + } + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> BOOST_SERIALIZATION_NVP(j1); + } + BOOST_CHECK(j == j1); + std::remove(testfile); + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_registered.cpp b/src/boost/libs/serialization/test/test_registered.cpp new file mode 100644 index 00000000..5a5ccdda --- /dev/null +++ b/src/boost/libs/serialization/test/test_registered.cpp @@ -0,0 +1,239 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_registered.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <cstddef> // NULL +#include <cstdio> // remove +#include <fstream> + +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include <boost/archive/archive_exception.hpp> +#include "test_tools.hpp" + +#include <boost/serialization/base_object.hpp> +#include <boost/serialization/type_info_implementation.hpp> + +class polymorphic_base +{ + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive & /* ar */, const unsigned int /* file_version */){ + } +public: + virtual ~polymorphic_base(){}; +}; + +class polymorphic_derived1 : public polymorphic_base +{ + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive &ar, const unsigned int /* file_version */){ + ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(polymorphic_base); + } +}; + +class polymorphic_derived2 : public polymorphic_base +{ + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive &ar, const unsigned int /* file_version */){ + ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(polymorphic_base); + } +}; + +// save derived polymorphic class +void save_derived(const char *testfile) +{ + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + + polymorphic_derived1 *rd1 = new polymorphic_derived1; + polymorphic_derived2 *rd2 = new polymorphic_derived2; + + // registration IS necessary when serializing pointers of + // polymorphic classes + oa.register_type(static_cast<polymorphic_derived1 *>(NULL)); + oa.register_type(static_cast<polymorphic_derived2 *>(NULL)); + oa << BOOST_SERIALIZATION_NVP(rd1); + oa << BOOST_SERIALIZATION_NVP(rd2); + + // the above opereration registers the derived classes as a side + // effect. Hence, instances can now be correctly serialized through + // a base class pointer. + polymorphic_base *rb1 = rd1; + polymorphic_base *rb2 = rd2; + oa << BOOST_SERIALIZATION_NVP(rb1); + oa << BOOST_SERIALIZATION_NVP(rb2); + + delete rd1; + delete rd2; +} + +// save derived polymorphic class +void load_derived(const char *testfile) +{ + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + + polymorphic_derived1 *rd1 = NULL; + polymorphic_derived2 *rd2 = NULL; + + // registration IS necessary when serializing pointers of + // polymorphic classes + ia.register_type(static_cast<polymorphic_derived1 *>(NULL)); + ia.register_type(static_cast<polymorphic_derived2 *>(NULL)); + + ia >> BOOST_SERIALIZATION_NVP(rd1); + + const boost::serialization::extended_type_info * p1; + p1 = & boost::serialization::type_info_implementation<polymorphic_derived1> + ::type::get_const_instance(); + + BOOST_CHECK(NULL != p1); + + const boost::serialization::extended_type_info * p2; + p2 = boost::serialization::type_info_implementation<polymorphic_derived1> + ::type::get_const_instance().get_derived_extended_type_info(*rd1); + + BOOST_CHECK(NULL != p2); + + BOOST_CHECK_MESSAGE(p1 == p2, "restored pointer d1 not of correct type"); + + ia >> BOOST_SERIALIZATION_NVP(rd2); + + BOOST_CHECK_MESSAGE( + & boost::serialization::type_info_implementation<polymorphic_derived2> + ::type::get_const_instance() + == + boost::serialization::type_info_implementation<polymorphic_derived2> + ::type::get_const_instance().get_derived_extended_type_info(*rd2), + "restored pointer d2 not of correct type" + ); + + polymorphic_base *rb1 = NULL; + polymorphic_base *rb2 = NULL; + + // the above opereration registers the derived classes as a side + // effect. Hence, instances can now be correctly serialized through + // a base class pointer. + ia >> BOOST_SERIALIZATION_NVP(rb1); + + BOOST_CHECK_MESSAGE( + rb1 == dynamic_cast<polymorphic_base *>(rd1), + "serialized pointers not correctly restored" + ); + + p1 = & boost::serialization::type_info_implementation<polymorphic_derived1> + ::type::get_const_instance(); + + BOOST_CHECK(NULL != p1); + + p2 = boost::serialization::type_info_implementation<polymorphic_base> + ::type::get_const_instance().get_derived_extended_type_info(*rb1); + + BOOST_CHECK(NULL != p2); + + BOOST_CHECK_MESSAGE(p1 == p2, "restored pointer b1 not of correct type"); + + ia >> BOOST_SERIALIZATION_NVP(rb2); + + BOOST_CHECK_MESSAGE( + rb2 == dynamic_cast<polymorphic_base *>(rd2), + "serialized pointers not correctly restored" + ); + + BOOST_CHECK_MESSAGE( + & boost::serialization::type_info_implementation<polymorphic_derived2> + ::type::get_const_instance() + == boost::serialization::type_info_implementation<polymorphic_base> + ::type::get_const_instance().get_derived_extended_type_info(*rb2), + "restored pointer b2 not of correct type" + ); + + delete rb1; + delete rb2; +} + +// save registered polymorphic class +void save_registered(const char *testfile) +{ + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + + polymorphic_base *rb1 = new polymorphic_derived1; + polymorphic_base *rb2 = new polymorphic_derived2; + + // registration (forward declaration) will permit correct serialization + // through a pointer to a base class + oa.register_type(static_cast<polymorphic_derived1 *>(NULL)); + oa.register_type(static_cast<polymorphic_derived2 *>(NULL)); + oa << BOOST_SERIALIZATION_NVP(rb1) << BOOST_SERIALIZATION_NVP(rb2); + + delete rb1; + delete rb2; +} + +// save registered polymorphic class +void load_registered(const char *testfile) +{ + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + + polymorphic_base *rb1 = NULL; + polymorphic_base *rb2 = NULL; + + // registration (forward declaration) will permit correct serialization + // through a pointer to a base class + ia.register_type(static_cast<polymorphic_derived1 *>(NULL)); + ia.register_type(static_cast<polymorphic_derived2 *>(NULL)); + ia >> BOOST_SERIALIZATION_NVP(rb1) >> BOOST_SERIALIZATION_NVP(rb2); + + BOOST_CHECK_MESSAGE( + & boost::serialization::type_info_implementation<polymorphic_derived1> + ::type::get_const_instance() + == boost::serialization::type_info_implementation<polymorphic_base> + ::type::get_const_instance().get_derived_extended_type_info(*rb1), + "restored pointer b1 not of correct type" + ); + + BOOST_CHECK_MESSAGE( + & boost::serialization::type_info_implementation<polymorphic_derived2> + ::type::get_const_instance() + == boost::serialization::type_info_implementation<polymorphic_base> + ::type::get_const_instance().get_derived_extended_type_info(*rb2), + "restored pointer b2 not of correct type" + ); + + delete rb1; + delete rb2; +} + +int +test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + + BOOST_REQUIRE(NULL != testfile); + + save_derived(testfile); + load_derived(testfile); + save_registered(testfile); + load_registered(testfile); + + std::remove(testfile); + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_reset_object_address.cpp b/src/boost/libs/serialization/test/test_reset_object_address.cpp new file mode 100644 index 00000000..b78d52f8 --- /dev/null +++ b/src/boost/libs/serialization/test/test_reset_object_address.cpp @@ -0,0 +1,412 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_reset_object_address.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +#include <sstream> +#include <cassert> +#include <cstdlib> // for rand() +#include <cstddef> // size_t + +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::rand; + using ::size_t; +} +#endif + +#include "test_tools.hpp" + +#include <boost/archive/text_oarchive.hpp> +#include <boost/archive/text_iarchive.hpp> +#include <boost/archive/polymorphic_text_oarchive.hpp> +#include <boost/archive/polymorphic_text_iarchive.hpp> + +#include <boost/serialization/list.hpp> +#include <boost/serialization/access.hpp> + +// Someday, maybe all tests will be converted to the unit test framework. +// but for now use the text execution monitor to be consistent with all +// the other tests. + +// simple test of untracked value +#include "A.hpp" +#include "A.ipp" + +void test1(){ + std::stringstream ss; + const A a; + { + boost::archive::text_oarchive oa(ss); + oa << a; + } + A a1; + { + boost::archive::text_iarchive ia(ss); + // load to temporary + A a2; + ia >> a2; + BOOST_CHECK_EQUAL(a, a2); + // move to final destination + a1 = a2; + ia.reset_object_address(& a1, & a2); + } + BOOST_CHECK_EQUAL(a, a1); +} + +// simple test of tracked value +class B { + friend class boost::serialization::access; + int m_i; + template<class Archive> + void serialize(Archive &ar, const unsigned int /*file_version*/){ + ar & m_i; + } +public: + bool operator==(const B & rhs) const { + return m_i == rhs.m_i; + } + B() : + m_i(std::rand()) + {} +}; + +//BOOST_TEST_DONT_PRINT_LOG_VALUE( B ) + +void test2(){ + std::stringstream ss; + B const b; + B const * const b_ptr = & b; + BOOST_CHECK_EQUAL(& b, b_ptr); + { + boost::archive::text_oarchive oa(ss); + oa << b; + oa << b_ptr; + } + B b1; + B * b1_ptr; + { + boost::archive::text_iarchive ia(ss); + // load to temporary + B b2; + ia >> b2; + BOOST_CHECK_EQUAL(b, b2); + // move to final destination + b1 = b2; + ia.reset_object_address(& b1, & b2); + ia >> b1_ptr; + } + BOOST_CHECK_EQUAL(b, b1); + BOOST_CHECK_EQUAL(& b1, b1_ptr); +} + +// check that nested member values are properly moved +class D { + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive &ar, const unsigned int /*file_version*/){ + ar & m_b; + } +public: + B m_b; + bool operator==(const D & rhs) const { + return m_b == rhs.m_b; + } + D(){} +}; + +//BOOST_TEST_DONT_PRINT_LOG_VALUE( D ) + +void test3(){ + std::stringstream ss; + D const d; + B const * const b_ptr = & d.m_b; + { + boost::archive::text_oarchive oa(ss); + oa << d; + oa << b_ptr; + } + D d1; + B * b1_ptr; + { + boost::archive::text_iarchive ia(ss); + D d2; + ia >> d2; + d1 = d2; + ia.reset_object_address(& d1, & d2); + ia >> b1_ptr; + } + BOOST_CHECK_EQUAL(d, d1); + BOOST_CHECK_EQUAL(* b_ptr, * b1_ptr); +} + +// check that data pointed to by pointer members is NOT moved +class E { + int m_i; + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive &ar, const unsigned int /*file_version*/){ + ar & m_i; + } +public: + bool operator==(const E &rhs) const { + return m_i == rhs.m_i; + } + E() : + m_i(std::rand()) + {} + E(const E & rhs) : + m_i(rhs.m_i) + {} +}; +//BOOST_TEST_DONT_PRINT_LOG_VALUE( E ) + +// check that moves don't move stuff pointed to +class F { + friend class boost::serialization::access; + E * m_eptr; + template<class Archive> + void serialize(Archive &ar, const unsigned int /*file_version*/){ + ar & m_eptr; + } +public: + bool operator==(const F &rhs) const { + return *m_eptr == *rhs.m_eptr; + } + F & operator=(const F & rhs) { + * m_eptr = * rhs.m_eptr; + return *this; + } + F(){ + m_eptr = new E; + } + F(const F & rhs){ + *this = rhs; + } + ~F(){ + delete m_eptr; + } +}; + +//BOOST_TEST_DONT_PRINT_LOG_VALUE( F ) + +void test4(){ + std::stringstream ss; + const F f; + { + boost::archive::text_oarchive oa(ss); + oa << f; + } + F f1; + { + boost::archive::text_iarchive ia(ss); + F f2; + ia >> f2; + f1 = f2; + ia.reset_object_address(& f1, & f2); + } + BOOST_CHECK_EQUAL(f, f1); +} + +// check that multiple moves keep track of the correct target +class G { + friend class boost::serialization::access; + A m_a1; + A m_a2; + A *m_pa2; + template<class Archive> + void save(Archive &ar, const unsigned int /*file_version*/) const { + ar << m_a1; + ar << m_a2; + ar << m_pa2; + } + template<class Archive> + void load(Archive &ar, const unsigned int /*file_version*/){ + A a; // temporary A + ar >> a; + m_a1 = a; + ar.reset_object_address(& m_a1, & a); + ar >> a; + m_a2 = a; + ar.reset_object_address(& m_a2, & a); + ar & m_pa2; + } + BOOST_SERIALIZATION_SPLIT_MEMBER() +public: + bool operator==(const G &rhs) const { + return + m_a1 == rhs.m_a1 + && m_a2 == rhs.m_a2 + && *m_pa2 == *rhs.m_pa2; + } + G & operator=(const G & rhs) { + m_a1 = rhs.m_a1; + m_a2 = rhs.m_a2; + m_pa2 = & m_a2; + return *this; + } + G(){ + m_pa2 = & m_a2; + } + G(const G & rhs){ + *this = rhs; + } + ~G(){} +}; + +//BOOST_TEST_DONT_PRINT_LOG_VALUE( G ) + +void test5(){ + std::stringstream ss; + const G g; + { + boost::archive::text_oarchive oa(ss); + oa << g; + } + G g1; + { + boost::archive::text_iarchive ia(ss); + ia >> g1; + } + BOOST_CHECK_EQUAL(g, g1); +} + +// joaquin's test - this tests the case where rest_object_address +// is applied to an item which in fact is not tracked so that +// the call is in fact superfluous. +struct foo +{ + int x; + +private: + friend class boost::serialization::access; + + template<class Archive> + void serialize(Archive &,const unsigned int) + { + } +}; + +struct bar +{ + foo f[2]; + foo* pf[2]; + +private: + friend class boost::serialization::access; + BOOST_SERIALIZATION_SPLIT_MEMBER() + + template<class Archive> + void save(Archive& ar,const unsigned int)const + { + for(int i=0;i<2;++i){ + ar<<f[i].x; + ar<<f[i]; + } + for(int j=0;j<2;++j){ + ar<<pf[j]; + } + } + + template<class Archive> + void load(Archive& ar,const unsigned int) + { + for(int i=0;i<2;++i){ + int x; + ar>>x; + f[i].x=x; + ar.reset_object_address(&f[i].x,&x); + ar>>f[i]; + } + for(int j=0;j<2;++j){ + ar>>pf[j]; + } + } +}; + +int test6() +{ + bar b; + b.f[0].x=0; + b.f[1].x=1; + b.pf[0]=&b.f[0]; + b.pf[1]=&b.f[1]; + + std::ostringstream oss; + { + boost::archive::text_oarchive oa(oss); + oa<<const_cast<const bar&>(b); + } + + bar b1; + b1.pf[0]=0; + b1.pf[1]=0; + + std::istringstream iss(oss.str()); + boost::archive::text_iarchive ia(iss); + ia>>b1; + BOOST_CHECK(b1.pf[0]==&b1.f[0]&&b1.pf[1]==&b1.f[1]); + + return 0; +} + +// test one of the collections +void test7(){ + std::stringstream ss; + B const b; + B const * const b_ptr = & b; + BOOST_CHECK_EQUAL(& b, b_ptr); + { + std::list<const B *> l; + l.push_back(b_ptr); + boost::archive::text_oarchive oa(ss); + oa << const_cast<const std::list<const B *> &>(l); + } + B b1; + { + std::list<B *> l; + boost::archive::text_iarchive ia(ss); + ia >> l; + delete l.front(); // prevent memory leak + } +} + +// test one of the collections with polymorphic archive +void test8(){ + std::stringstream ss; + B const b; + B const * const b_ptr = & b; + BOOST_CHECK_EQUAL(& b, b_ptr); + { + std::list<const B *> l; + l.push_back(b_ptr); + boost::archive::polymorphic_text_oarchive oa(ss); + boost::archive::polymorphic_oarchive & poa = oa; + poa << const_cast<const std::list<const B *> &>(l); + } + B b1; + { + std::list<B *> l; + boost::archive::polymorphic_text_iarchive ia(ss); + boost::archive::polymorphic_iarchive & pia = ia; + pia >> l; + delete l.front(); // prevent memory leak + } +} + +int test_main(int /* argc */, char * /* argv */[]) +{ + test1(); + test2(); + test3(); + test4(); + test5(); + test6(); + test7(); + test8(); + return EXIT_SUCCESS; +} diff --git a/src/boost/libs/serialization/test/test_set.cpp b/src/boost/libs/serialization/test/test_set.cpp new file mode 100644 index 00000000..51fef489 --- /dev/null +++ b/src/boost/libs/serialization/test/test_set.cpp @@ -0,0 +1,111 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_set.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// (C) Copyright 2014 Jim Bell +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <cstddef> // NULLsize_t +#include <cstdio> // remove +#include <fstream> + +#include <algorithm> // std::copy +#include <vector> + +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::size_t; +} +#endif + +#include <boost/detail/workaround.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include <boost/archive/archive_exception.hpp> + +#include "test_tools.hpp" + +#include <boost/serialization/nvp.hpp> +#include <boost/serialization/set.hpp> + +#include "A.hpp" +#include "A.ipp" + +void +test_set(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + // test array of objects + std::set<A> aset; + aset.insert(A()); + aset.insert(A()); + const A * a_ptr = & * aset.begin(); + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("aset", aset); + // serialize a pointer into the set + oa << boost::serialization::make_nvp("a_ptr", a_ptr); + } + std::set<A> aset1; + A * a_ptr1; + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("aset", aset1); + // deserialize a pointer into the set + ia >> boost::serialization::make_nvp("a_ptr1", a_ptr1); + } + BOOST_CHECK_EQUAL(aset, aset1); + BOOST_CHECK_EQUAL(*a_ptr1, * aset1.begin()); + BOOST_CHECK_EQUAL(a_ptr1, & * aset1.begin()); + std::remove(testfile); +} + +void +test_multiset(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + std::multiset<A> amultiset; + amultiset.insert(A()); + amultiset.insert(A()); + const A * a_ptr = & * amultiset.begin(); + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("amultiset", amultiset); + // serialize a pointer into the set + oa << boost::serialization::make_nvp("a_ptr", a_ptr); + } + std::multiset<A> amultiset1; + A * a_ptr1; + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("amultiset", amultiset1); + // deserialize a pointer into the set + ia >> boost::serialization::make_nvp("a_ptr1", a_ptr1); + } + BOOST_CHECK(amultiset == amultiset1); + BOOST_CHECK_EQUAL(*a_ptr1, * amultiset1.begin()); + BOOST_CHECK_EQUAL(a_ptr1, & * amultiset1.begin()); + std::remove(testfile); +} + +int test_main( int /* argc */, char* /* argv */[] ){ + test_set(); + test_multiset(); + + return EXIT_SUCCESS; +} diff --git a/src/boost/libs/serialization/test/test_set_boost_unordered.cpp b/src/boost/libs/serialization/test/test_set_boost_unordered.cpp new file mode 100644 index 00000000..ce29374c --- /dev/null +++ b/src/boost/libs/serialization/test/test_set_boost_unordered.cpp @@ -0,0 +1,123 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_set.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// (C) Copyright 2014 Jim Bell +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <cstddef> // NULLsize_t +#include <cstdio> // remove +#include <fstream> + +#include <algorithm> // std::copy +#include <vector> + +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::size_t; +} +#endif + +#include <boost/detail/workaround.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include <boost/archive/archive_exception.hpp> + +#include "test_tools.hpp" + +#include <boost/serialization/nvp.hpp> +#include <boost/serialization/set.hpp> + +#include "A.hpp" +#include "A.ipp" + +#include <boost/serialization/boost_unordered_set.hpp> +#include <functional> // requires changeset [69520]; Ticket #5254 + +namespace boost { + template<> + struct hash<A> { + std::size_t operator()(const A& a) const { + return static_cast<std::size_t>(a); + } + }; +} // namespace boost + +void +test_unordered_set(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + // test array of objects + boost::unordered_set<A> anunordered_set; + A a, a1; + anunordered_set.insert(a); + anunordered_set.insert(a1); + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("anunordered_set", anunordered_set); + } + boost::unordered_set<A> anunordered_set1; + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("anunordered_set", anunordered_set1); + } + std::vector<A> tvec, tvec1; + tvec.clear(); + tvec1.clear(); + std::copy(anunordered_set.begin(), anunordered_set.end(), std::back_inserter(tvec)); + std::sort(tvec.begin(), tvec.end()); + std::copy(anunordered_set1.begin(), anunordered_set1.end(), std::back_inserter(tvec1)); + std::sort(tvec1.begin(), tvec1.end()); + BOOST_CHECK(tvec == tvec1); + std::remove(testfile); +} + +void +test_unordered_multiset(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + boost::unordered_multiset<A> anunordered_multiset; + anunordered_multiset.insert(A()); + anunordered_multiset.insert(A()); + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("anunordered_multiset", anunordered_multiset); + } + boost::unordered_multiset<A> anunordered_multiset1; + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("anunordered_multiset", anunordered_multiset1); + } + + std::vector<A> tvec, tvec1; + tvec.clear(); + tvec1.clear(); + std::copy(anunordered_multiset.begin(), anunordered_multiset.end(), std::back_inserter(tvec)); + std::sort(tvec.begin(), tvec.end()); + std::copy(anunordered_multiset1.begin(), anunordered_multiset1.end(), std::back_inserter(tvec1)); + std::sort(tvec1.begin(), tvec1.end()); + BOOST_CHECK(tvec == tvec1); + + std::remove(testfile); +} + +int test_main( int /* argc */, char* /* argv */[] ){ + test_unordered_set(); + test_unordered_multiset(); + return EXIT_SUCCESS; +} diff --git a/src/boost/libs/serialization/test/test_set_hashed.cpp b/src/boost/libs/serialization/test/test_set_hashed.cpp new file mode 100644 index 00000000..8379c77f --- /dev/null +++ b/src/boost/libs/serialization/test/test_set_hashed.cpp @@ -0,0 +1,262 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_set.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// (C) Copyright 2014 Jim Bell +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <cstddef> // NULLsize_t +#include <cstdio> // remove +#include <fstream> + +#include <algorithm> // std::copy +#include <vector> + +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::size_t; +} +#endif + +#include <boost/detail/workaround.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include <boost/archive/archive_exception.hpp> + +#include "test_tools.hpp" + +#include <boost/serialization/nvp.hpp> +#include <boost/serialization/set.hpp> + +#include "A.hpp" +#include "A.ipp" + +void +test_set(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + // test array of objects + std::set<A> aset; + aset.insert(A()); + aset.insert(A()); + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("aset", aset); + } + std::set<A> aset1; + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("aset", aset1); + } + BOOST_CHECK(aset == aset1); + std::remove(testfile); +} + +void +test_multiset(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + std::multiset<A> amultiset; + amultiset.insert(A()); + amultiset.insert(A()); + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("amultiset", amultiset); + } + std::multiset<A> amultiset1; + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("amultiset", amultiset1); + } + BOOST_CHECK(amultiset == amultiset1); + std::remove(testfile); +} + +#ifdef BOOST_HAS_HASH + +#include <boost/serialization/hash_set.hpp> + +namespace BOOST_STD_EXTENSION_NAMESPACE { + template<> + struct hash<A> { + std::size_t operator()(const A& a) const { + return static_cast<std::size_t>(a); + } + }; +} + +void +test_hash_set(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + // test array of objects + BOOST_STD_EXTENSION_NAMESPACE::hash_set<A> ahash_set; + A a, a1; + ahash_set.insert(a); + ahash_set.insert(a1); + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("ahash_set", ahash_set); + } + BOOST_STD_EXTENSION_NAMESPACE::hash_set<A> ahash_set1; + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("ahash_set", ahash_set1); + } + std::vector<A> tvec, tvec1; + tvec.clear(); + tvec1.clear(); + std::copy(ahash_set.begin(), ahash_set.end(), std::back_inserter(tvec)); + std::sort(tvec.begin(), tvec.end()); + std::copy(ahash_set1.begin(), ahash_set1.end(), std::back_inserter(tvec1)); + std::sort(tvec1.begin(), tvec1.end()); + BOOST_CHECK(tvec == tvec1); + std::remove(testfile); +} + +void +test_hash_multiset(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + BOOST_STD_EXTENSION_NAMESPACE::hash_multiset<A> ahash_multiset; + ahash_multiset.insert(A()); + ahash_multiset.insert(A()); + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("ahash_multiset", ahash_multiset); + } + BOOST_STD_EXTENSION_NAMESPACE::hash_multiset<A> ahash_multiset1; + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("ahash_multiset", ahash_multiset1); + } + + std::vector<A> tvec, tvec1; + tvec.clear(); + tvec1.clear(); + std::copy(ahash_multiset.begin(), ahash_multiset.end(), std::back_inserter(tvec)); + std::sort(tvec.begin(), tvec.end()); + std::copy(ahash_multiset1.begin(), ahash_multiset1.end(), std::back_inserter(tvec1)); + std::sort(tvec1.begin(), tvec1.end()); + BOOST_CHECK(tvec == tvec1); + + std::remove(testfile); +} +#endif + +#ifndef BOOST_NO_CXX11_HDR_UNORDERED_SET + +#include <boost/serialization/unordered_set.hpp> +#include <functional> // requires changeset [69520]; Ticket #5254 + +namespace std { + template<> + struct hash<A> { + std::size_t operator()(const A& a) const { + return static_cast<std::size_t>(a); + } + }; +} // namespace std + +void +test_unordered_set(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + // test array of objects + std::unordered_set<A> anunordered_set; + A a, a1; + anunordered_set.insert(a); + anunordered_set.insert(a1); + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("anunordered_set", anunordered_set); + } + std::unordered_set<A> anunordered_set1; + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("anunordered_set", anunordered_set1); + } + std::vector<A> tvec, tvec1; + tvec.clear(); + tvec1.clear(); + std::copy(anunordered_set.begin(), anunordered_set.end(), std::back_inserter(tvec)); + std::sort(tvec.begin(), tvec.end()); + std::copy(anunordered_set1.begin(), anunordered_set1.end(), std::back_inserter(tvec1)); + std::sort(tvec1.begin(), tvec1.end()); + BOOST_CHECK(tvec == tvec1); + std::remove(testfile); +} + +void +test_unordered_multiset(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + std::unordered_multiset<A> anunordered_multiset; + anunordered_multiset.insert(A()); + anunordered_multiset.insert(A()); + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("anunordered_multiset", anunordered_multiset); + } + std::unordered_multiset<A> anunordered_multiset1; + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("anunordered_multiset", anunordered_multiset1); + } + + std::vector<A> tvec, tvec1; + tvec.clear(); + tvec1.clear(); + std::copy(anunordered_multiset.begin(), anunordered_multiset.end(), std::back_inserter(tvec)); + std::sort(tvec.begin(), tvec.end()); + std::copy(anunordered_multiset1.begin(), anunordered_multiset1.end(), std::back_inserter(tvec1)); + std::sort(tvec1.begin(), tvec1.end()); + BOOST_CHECK(tvec == tvec1); + + std::remove(testfile); +} +#endif + +int test_main( int /* argc */, char* /* argv */[] ){ + test_set(); + test_multiset(); + + #ifdef BOOST_HAS_HASH + test_hash_set(); + test_hash_multiset(); + #endif + + #ifndef BOOST_NO_CXX11_HDR_UNORDERED_SET + test_unordered_set(); + test_unordered_multiset(); + #endif + + return EXIT_SUCCESS; +} diff --git a/src/boost/libs/serialization/test/test_set_unordered.cpp b/src/boost/libs/serialization/test/test_set_unordered.cpp new file mode 100644 index 00000000..31ec256a --- /dev/null +++ b/src/boost/libs/serialization/test/test_set_unordered.cpp @@ -0,0 +1,123 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_set.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// (C) Copyright 2014 Jim Bell +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <cstddef> // NULLsize_t +#include <cstdio> // remove +#include <fstream> + +#include <algorithm> // std::copy +#include <vector> + +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::size_t; +} +#endif + +#include <boost/detail/workaround.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include <boost/archive/archive_exception.hpp> + +#include "test_tools.hpp" + +#include <boost/serialization/nvp.hpp> +#include <boost/serialization/set.hpp> + +#include "A.hpp" +#include "A.ipp" + +#include <boost/serialization/unordered_set.hpp> +#include <functional> // requires changeset [69520]; Ticket #5254 + +namespace std { + template<> + struct hash<A> { + std::size_t operator()(const A& a) const { + return static_cast<std::size_t>(a); + } + }; +} // namespace std + +void +test_unordered_set(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + // test array of objects + std::unordered_set<A> anunordered_set; + A a, a1; + anunordered_set.insert(a); + anunordered_set.insert(a1); + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("anunordered_set", anunordered_set); + } + std::unordered_set<A> anunordered_set1; + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("anunordered_set", anunordered_set1); + } + std::vector<A> tvec, tvec1; + tvec.clear(); + tvec1.clear(); + std::copy(anunordered_set.begin(), anunordered_set.end(), std::back_inserter(tvec)); + std::sort(tvec.begin(), tvec.end()); + std::copy(anunordered_set1.begin(), anunordered_set1.end(), std::back_inserter(tvec1)); + std::sort(tvec1.begin(), tvec1.end()); + BOOST_CHECK(tvec == tvec1); + std::remove(testfile); +} + +void +test_unordered_multiset(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + std::unordered_multiset<A> anunordered_multiset; + anunordered_multiset.insert(A()); + anunordered_multiset.insert(A()); + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("anunordered_multiset", anunordered_multiset); + } + std::unordered_multiset<A> anunordered_multiset1; + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("anunordered_multiset", anunordered_multiset1); + } + + std::vector<A> tvec, tvec1; + tvec.clear(); + tvec1.clear(); + std::copy(anunordered_multiset.begin(), anunordered_multiset.end(), std::back_inserter(tvec)); + std::sort(tvec.begin(), tvec.end()); + std::copy(anunordered_multiset1.begin(), anunordered_multiset1.end(), std::back_inserter(tvec1)); + std::sort(tvec1.begin(), tvec1.end()); + BOOST_CHECK(tvec == tvec1); + + std::remove(testfile); +} + +int test_main( int /* argc */, char* /* argv */[] ){ + test_unordered_set(); + test_unordered_multiset(); + return EXIT_SUCCESS; +} diff --git a/src/boost/libs/serialization/test/test_shared_ptr.cpp b/src/boost/libs/serialization/test/test_shared_ptr.cpp new file mode 100644 index 00000000..2b4a8b1f --- /dev/null +++ b/src/boost/libs/serialization/test/test_shared_ptr.cpp @@ -0,0 +1,322 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_shared_ptr.cpp + +// (C) Copyright 2002 Robert Ramey- http://www.rrsd.com - David Tonge . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) +// +// See http://www.boost.org for updates, documentation, and revision history. + +#include <cstddef> // NULL +#include <cstdio> // remove +#include <fstream> + +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include <boost/serialization/nvp.hpp> +#include <boost/serialization/export.hpp> +#include <boost/serialization/shared_ptr.hpp> +#include <boost/serialization/weak_ptr.hpp> + +#include "test_tools.hpp" + +// This is a simple class. It contains a counter of the number +// of objects of this class which have been instantiated. +class A +{ +private: + friend class boost::serialization::access; + int x; + template<class Archive> + void serialize(Archive & ar, const unsigned int /* file_version */){ + ar & BOOST_SERIALIZATION_NVP(x); + } + A(A const & rhs); + A& operator=(A const & rhs); +public: + static int count; + bool operator==(const A & rhs) const { + return x == rhs.x; + } + A(){++count;} // default constructor + virtual ~A(){--count;} // default destructor +}; + +BOOST_SERIALIZATION_SHARED_PTR(A) + +int A::count = 0; + +// B is a subclass of A +class B : public A +{ +private: + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive & ar, const unsigned int /* file_version */){ + ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(A); + } +public: + static int count; + B() : A() {}; + virtual ~B() {}; +}; + +// B needs to be exported because its serialized via a base class pointer +BOOST_CLASS_EXPORT(B) +BOOST_SERIALIZATION_SHARED_PTR(B) + +// test a non-polymorphic class +class C +{ +private: + friend class boost::serialization::access; + int z; + template<class Archive> + void serialize(Archive & ar, const unsigned int /* file_version */){ + ar & BOOST_SERIALIZATION_NVP(z); + } +public: + static int count; + bool operator==(const C & rhs) const { + return z == rhs.z; + } + C() : + z(++count) // default constructor + {} + virtual ~C(){--count;} // default destructor +}; + +int C::count = 0; + +template<class SP> +void save(const char * testfile, const SP & spa) +{ + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << BOOST_SERIALIZATION_NVP(spa); +} + +template<class SP> +void load(const char * testfile, SP & spa) +{ + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> BOOST_SERIALIZATION_NVP(spa); +} + +// trivial test +template<class SP> +void save_and_load(SP & spa) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + save(testfile, spa); + SP spa1; + load(testfile, spa1); + + BOOST_CHECK( + (spa.get() == NULL && spa1.get() == NULL) + || * spa == * spa1 + ); + std::remove(testfile); +} + +template<class SP> +void save2( + const char * testfile, + const SP & first, + const SP & second +){ + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << BOOST_SERIALIZATION_NVP(first); + oa << BOOST_SERIALIZATION_NVP(second); +} + +template<class SP> +void load2( + const char * testfile, + SP & first, + SP & second) +{ + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> BOOST_SERIALIZATION_NVP(first); + ia >> BOOST_SERIALIZATION_NVP(second); +} + +// Run tests by serializing two shared_ptrs into an archive, +// clearing them (deleting the objects) and then reloading the +// objects back from an archive. +template<class SP> +void save_and_load2(SP & first, SP & second) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + save2(testfile, first, second); + + // Clear the pointers, thereby destroying the objects they contain + first.reset(); + second.reset(); + + load2(testfile, first, second); + + BOOST_CHECK(first == second); + std::remove(testfile); +} + +template<class SP, class WP> +void save3( + const char * testfile, + SP & first, + SP & second, + WP & third +){ + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << BOOST_SERIALIZATION_NVP(third); + oa << BOOST_SERIALIZATION_NVP(first); + oa << BOOST_SERIALIZATION_NVP(second); +} + +template<class SP, class WP> +void load3( + const char * testfile, + SP & first, + SP & second, + WP & third +){ + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + // note that we serialize the weak pointer first + ia >> BOOST_SERIALIZATION_NVP(third); + // inorder to test that a temporarily solitary weak pointer + // correctly restored. + ia >> BOOST_SERIALIZATION_NVP(first); + ia >> BOOST_SERIALIZATION_NVP(second); +} + +template<class SP, class WP> +void save_and_load3( + SP & first, + SP & second, + WP & third +){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + save3(testfile, first, second, third); + + // Clear the pointers, thereby destroying the objects they contain + first.reset(); + second.reset(); + third.reset(); + + load3(testfile, first, second, third); + + BOOST_CHECK(first == second); + BOOST_CHECK(first == third.lock()); + std::remove(testfile); +} + +template<class SP> +void save4(const char * testfile, const SP & spc) +{ + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << BOOST_SERIALIZATION_NVP(spc); +} + +template<class SP> +void load4(const char * testfile, SP & spc) +{ + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> BOOST_SERIALIZATION_NVP(spc); +} + +// trivial test +template<class SP> +void save_and_load4(SP & spc) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + save4(testfile, spc); + SP spc1; + load4(testfile, spc1); + + BOOST_CHECK( + (spc.get() == NULL && spc1.get() == NULL) + || * spc == * spc1 + ); + std::remove(testfile); +} + +// This does the tests +template<template<class T> class SPT , template<class T> class WPT > +bool test(){ + { + SPT<A> spa; + // These are our shared_ptrs + spa = SPT<A>(new A); + SPT<A> spa1 = spa; + spa1 = spa; + } + { + // These are our shared_ptrs + SPT<A> spa; + + // trivial test 1 + save_and_load(spa); + + //trivival test 2 + spa = SPT<A>(new A); + save_and_load(spa); + + // Try to save and load pointers to As + spa = SPT<A>(new A); + SPT<A> spa1 = spa; + save_and_load2(spa, spa1); + + // Try to save and load pointers to Bs + spa = SPT<A>(new B); + spa1 = spa; + save_and_load2(spa, spa1); + + // test a weak pointer + spa = SPT<A>(new A); + spa1 = spa; + WPT<A> wp = spa; + save_and_load3(spa, spa1, wp); + + // obj of type B gets destroyed + // as smart_ptr goes out of scope + } + BOOST_CHECK(A::count == 0); + { + // Try to save and load pointers to Cs + SPT<C> spc; + spc = SPT<C>(new C); + save_and_load4(spc); + } + BOOST_CHECK(C::count == 0); + return true; +} +// This does the tests +int test_main(int /* argc */, char * /* argv */[]) +{ + bool result = true; + result &= test<boost::shared_ptr, boost::weak_ptr>(); + #ifndef BOOST_NO_CXX11_SMART_PTR + result &= test<std::shared_ptr, std::weak_ptr>(); + #endif + return result ? EXIT_SUCCESS : EXIT_FAILURE; +} + diff --git a/src/boost/libs/serialization/test/test_shared_ptr_132.cpp b/src/boost/libs/serialization/test/test_shared_ptr_132.cpp new file mode 100644 index 00000000..f0faaa86 --- /dev/null +++ b/src/boost/libs/serialization/test/test_shared_ptr_132.cpp @@ -0,0 +1,230 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_shared_ptr.cpp + +// (C) Copyright 2002 Robert Ramey- http://www.rrsd.com - David Tonge . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) +// +// See http://www.boost.org for updates, documentation, and revision history. + +#include <cstddef> // NULL +#include <fstream> + +#include <cstdio> // remove +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include "test_tools.hpp" + +#include <boost/serialization/shared_ptr_132.hpp> +#include <boost/serialization/shared_ptr.hpp> +#include <boost/serialization/weak_ptr.hpp> +#include <boost/serialization/split_member.hpp> + +#include <boost/preprocessor/stringize.hpp> + +#include <boost/serialization/nvp.hpp> +#include <boost/serialization/export.hpp> + +// This is a simple class. It contains a counter of the number +// of objects of this class which have been instantiated. +class A +{ +private: + friend class boost::serialization::access; + int x; + template<class Archive> + void save(Archive & ar, const unsigned int /* file_version */) const { + ar << BOOST_SERIALIZATION_NVP(x); + } + template<class Archive> + void load(Archive & ar, const unsigned int /* file_version */) { + ar >> BOOST_SERIALIZATION_NVP(x); + } + BOOST_SERIALIZATION_SPLIT_MEMBER() +public: + static int count; + bool operator==(const A & rhs) const { + return x == rhs.x; + } + A(){++count;} // default constructor + virtual ~A(){--count;} // default destructor +}; + +BOOST_SERIALIZATION_SHARED_PTR(A) + +// B is a subclass of A +class B : public A +{ +private: + friend class boost::serialization::access; + template<class Archive> + void save(Archive & ar, const unsigned int /* file_version */ )const { + ar << BOOST_SERIALIZATION_BASE_OBJECT_NVP(A); + } + template<class Archive> + void load(Archive & ar, const unsigned int /* file_version */){ + ar >> BOOST_SERIALIZATION_BASE_OBJECT_NVP(A); + } + BOOST_SERIALIZATION_SPLIT_MEMBER() +public: + static int count; + B() : A() {}; + virtual ~B() {}; +}; + +// B needs to be exported because its serialized via a base class pointer +BOOST_SHARED_POINTER_EXPORT(B) +BOOST_SERIALIZATION_SHARED_PTR(B) + +int A::count = 0; + +template<class T> +void save(const char * testfile, const T & spa) +{ + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << BOOST_SERIALIZATION_NVP(spa); +} + +template<class T> +void load(const char * testfile, T & spa) +{ + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> BOOST_SERIALIZATION_NVP(spa); +} + +// trivial test +template<class T> +void save_and_load(const T & spa) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + save(testfile, spa); + + // note that we're loading to a current version of shared_ptr + // regardless of the orignal saved type - this tests backward + // archive compatibility + boost::shared_ptr<A> spa1; + load(testfile, spa1); + + BOOST_CHECK( + (spa.get() == NULL && spa1.get() == NULL) + || * spa == * spa1 + ); + std::remove(testfile); +} + +template<class T> +void save2( + const char * testfile, + const T & first, + const T & second +){ + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << BOOST_SERIALIZATION_NVP(first); + oa << BOOST_SERIALIZATION_NVP(second); +} + +template<class T> +void load2( + const char * testfile, + T & first, + T & second) +{ + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> BOOST_SERIALIZATION_NVP(first); + ia >> BOOST_SERIALIZATION_NVP(second); +} + +// Run tests by serializing two shared_ptrs into an archive, +// clearing them (deleting the objects) and then reloading the +// objects back from an archive. +template<class T> +void save_and_load2(T & first, T & second) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + save2(testfile, first, second); + + // Clear the pointers, thereby destroying the objects they contain + first.reset(); + second.reset(); + + boost::shared_ptr<A> first1, second1; + load2(testfile, first1, second1); + + BOOST_CHECK(first1 == second1); + std::remove(testfile); +} + +template<class T> +void save3( + const char * testfile, + const T & first, + const T & second, + const T & third +){ + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << BOOST_SERIALIZATION_NVP(third); + oa << BOOST_SERIALIZATION_NVP(first); + oa << BOOST_SERIALIZATION_NVP(second); +} + +template<class T> +void load3( + const char * testfile, + T & first, + T & second, + T & third +){ + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + // note that we serialize the weak pointer first + ia >> BOOST_SERIALIZATION_NVP(third); + // inorder to test that a temporarily solitary weak pointer + // correcttly restored. + ia >> BOOST_SERIALIZATION_NVP(first); + ia >> BOOST_SERIALIZATION_NVP(second); +} + +// This does the tests +int test_main(int /* argc */, char * /* argv */[]) +{ + // These are our shared_ptrs + boost_132::shared_ptr<A> spa; + + // trivial test 1 + save_and_load(spa); + + //trivial test 2 + spa.reset(); + spa = boost_132::shared_ptr<A>(new A); + save_and_load(spa); + + // Try to save and load pointers to As, to a text archive + spa = boost_132::shared_ptr<A>(new A); + boost_132::shared_ptr<A> spa1 = spa; + save_and_load2(spa, spa1); + + // Try to save and load pointers to Bs, to a text archive + spa = boost_132::shared_ptr<A>(new B); + save_and_load(spa); + + spa1 = spa; + save_and_load2(spa, spa1); + + // obj of type B gets destroyed + // as smart_ptr goes out of scope + return EXIT_SUCCESS; +} diff --git a/src/boost/libs/serialization/test/test_shared_ptr_multi_base.cpp b/src/boost/libs/serialization/test/test_shared_ptr_multi_base.cpp new file mode 100644 index 00000000..7060f080 --- /dev/null +++ b/src/boost/libs/serialization/test/test_shared_ptr_multi_base.cpp @@ -0,0 +1,302 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_shared_ptr_multi_base.cpp + +// (C) Copyright 2002 Robert Ramey- http://www.rrsd.com and Takatoshi Kondo. +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) +// +// See http://www.boost.org for updates, documentation, and revision history. + +#include <cstddef> // NULL +#include <cstdio> // remove +#include <fstream> + +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include <boost/serialization/nvp.hpp> +#include <boost/serialization/export.hpp> + +#include <boost/serialization/shared_ptr.hpp> +#include <boost/serialization/weak_ptr.hpp> + +#include "test_tools.hpp" + +struct Base1 { + Base1() {} + Base1(int x) : m_x(1 + x) {} + virtual ~Base1(){ + } + int m_x; + // serialize + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive &ar, const unsigned int /* file_version */) + { + ar & BOOST_SERIALIZATION_NVP(m_x); + } +}; + +struct Base2 { + Base2() {} + Base2(int x) : m_x(2 + x) {} + int m_x; + virtual ~Base2(){ + } + // serialize + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive &ar, const unsigned int /* file_version */) + { + ar & BOOST_SERIALIZATION_NVP(m_x); + } +}; + +struct Base3 { + Base3() {} + Base3(int x) : m_x(3 + x) {} + virtual ~Base3(){ + } + int m_x; + // serialize + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive &ar, const unsigned int /* file_version */) + { + ar & BOOST_SERIALIZATION_NVP(m_x); + } +}; + +// Sub is a subclass of Base1, Base1 and Base3. +struct Sub:public Base1, public Base2, public Base3 { + static int count; + Sub() { + ++count; + } + Sub(int x) : + Base1(x), + Base2(x), + m_x(x) + { + ++count; + } + Sub(const Sub & rhs) : + m_x(rhs.m_x) + { + ++count; + } + virtual ~Sub() { + assert(0 < count); + --count; + } + int m_x; + // serialize + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive &ar, const unsigned int /* file_version */) + { + ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(Base1); + ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(Base2); + ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(Base3); + ar & BOOST_SERIALIZATION_NVP(m_x); + } +}; + +// Sub needs to be exported because its serialized via a base class pointer +BOOST_CLASS_EXPORT(Sub) +BOOST_SERIALIZATION_SHARED_PTR(Sub) + +int Sub::count = 0; + +template <class FIRST, class SECOND> +void save2( + const char * testfile, + const FIRST& first, + const SECOND& second +){ + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << BOOST_SERIALIZATION_NVP(first); + oa << BOOST_SERIALIZATION_NVP(second); +} + +template <class FIRST, class SECOND> +void load2( + const char * testfile, + FIRST& first, + SECOND& second) +{ + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> BOOST_SERIALIZATION_NVP(first); + ia >> BOOST_SERIALIZATION_NVP(second); +} + +// Run tests by serializing two shared_ptrs into an archive, +// clearing them (deleting the objects) and then reloading the +// objects back from an archive. + +template<class T, class U> +boost::shared_ptr<T> dynamic_pointer_cast(boost::shared_ptr<U> const & u) +BOOST_NOEXCEPT +{ + return boost::dynamic_pointer_cast<T>(u); +} + +#ifndef BOOST_NO_CXX11_SMART_PTR +template<class T, class U> +std::shared_ptr<T> dynamic_pointer_cast(std::shared_ptr<U> const & u) +BOOST_NOEXCEPT +{ + return std::dynamic_pointer_cast<T>(u); +} +#endif + +// Serialization sequence +// First, shared_ptr +// Second, weak_ptr +template <class SP, class WP> +void shared_weak( + SP & first, + WP & second +){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + int firstm = first->m_x; + + BOOST_REQUIRE(! second.expired()); + int secondm = second.lock()->m_x; + save2(testfile, first, second); + + // Clear the pointers, thereby destroying the objects they contain + second.reset(); + first.reset(); + + load2(testfile, first, second); + BOOST_CHECK(! second.expired()); + + // Check data member + BOOST_CHECK(firstm == first->m_x); + BOOST_CHECK(secondm == second.lock()->m_x); + // Check pointer to vtable + BOOST_CHECK(::dynamic_pointer_cast<Sub>(first)); + BOOST_CHECK(::dynamic_pointer_cast<Sub>(second.lock())); + + std::remove(testfile); +} + +// Serialization sequence +// First, weak_ptr +// Second, shared_ptr +template <class WP, class SP> +void weak_shared( + WP & first, + SP & second +){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + BOOST_CHECK(! first.expired()); + int firstm = first.lock()->m_x; + int secondm = second->m_x; + save2(testfile, first, second); + + // Clear the pointers, thereby destroying the objects they contain + first.reset(); + second.reset(); + + load2(testfile, first, second); + BOOST_CHECK(! first.expired()); + + // Check data member + BOOST_CHECK(firstm == first.lock()->m_x); + BOOST_CHECK(secondm == second->m_x); + // Check pointer to vtable + BOOST_CHECK(::dynamic_pointer_cast<Sub>(first.lock())); + BOOST_CHECK(::dynamic_pointer_cast<Sub>(second)); + + std::remove(testfile); +} + +// This does the tests +template<template<class T> class SPT, template<class T> class WPT> +bool test(){ + // Both Sub + SPT<Sub> tc1_sp(new Sub(10)); + WPT<Sub> tc1_wp(tc1_sp); + shared_weak(tc1_sp, tc1_wp); + weak_shared(tc1_wp, tc1_sp); + tc1_sp.reset(); + BOOST_CHECK(0 == Sub::count); + + // Sub and Base1 + SPT<Sub> tc2_sp(new Sub(10)); + WPT<Base1> tc2_wp(tc2_sp); + shared_weak(tc2_sp, tc2_wp); + weak_shared(tc2_wp, tc2_sp); + tc2_sp.reset(); + BOOST_CHECK(0 == Sub::count); + + // Sub and Base2 + SPT<Sub> tc3_sp(new Sub(10)); + WPT<Base2> tc3_wp(tc3_sp); + shared_weak(tc3_sp, tc3_wp); + weak_shared(tc3_wp, tc3_sp); + tc3_sp.reset(); + BOOST_CHECK(0 == Sub::count); + + // Sub and Base3 + SPT<Sub> tc4_sp(new Sub(10)); + WPT<Base3> tc4_wp(tc4_sp); + shared_weak(tc4_sp, tc4_wp); + weak_shared(tc4_wp, tc4_sp); + tc4_sp.reset(); + BOOST_CHECK(0 == Sub::count); + + // Base1 and Base2 + SPT<Sub> tc5_sp_tmp(new Sub(10)); + SPT<Base1> tc5_sp(tc5_sp_tmp); + WPT<Base2> tc5_wp(tc5_sp_tmp); + tc5_sp_tmp.reset(); + shared_weak(tc5_sp, tc5_wp); + weak_shared(tc5_wp, tc5_sp); + tc5_sp.reset(); + BOOST_CHECK(0 == Sub::count); + + // Base2 and Base3 + SPT<Sub> tc6_sp_tmp(new Sub(10)); + SPT<Base2> tc6_sp(tc6_sp_tmp); + WPT<Base3> tc6_wp(tc6_sp_tmp); + tc6_sp_tmp.reset(); + shared_weak(tc6_sp, tc6_wp); + weak_shared(tc6_wp, tc6_sp); + tc6_sp.reset(); + BOOST_CHECK(0 == Sub::count); + + // Base3 and Base1 + SPT<Sub> tc7_sp_tmp(new Sub(10)); + SPT<Base3> tc7_sp(tc7_sp_tmp); + WPT<Base1> tc7_wp(tc7_sp_tmp); + tc7_sp_tmp.reset(); + shared_weak(tc7_sp, tc7_wp); + weak_shared(tc7_wp, tc7_sp); + tc7_sp.reset(); + BOOST_CHECK(0 == Sub::count); + + return true; +} + +// This does the tests +int test_main(int /* argc */, char * /* argv */[]) +{ + bool result = true; + result &= test<boost::shared_ptr, boost::weak_ptr>(); + #ifndef BOOST_NO_CXX11_SMART_PTR + result &= test<std::shared_ptr, std::weak_ptr>(); + #endif + return result ? EXIT_SUCCESS : EXIT_FAILURE; +} diff --git a/src/boost/libs/serialization/test/test_simple_class.cpp b/src/boost/libs/serialization/test/test_simple_class.cpp new file mode 100644 index 00000000..8d396d45 --- /dev/null +++ b/src/boost/libs/serialization/test/test_simple_class.cpp @@ -0,0 +1,83 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_simple_class.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +// invoke header for a custom archive test. + +#include <cstddef> // NULL +#include <cstdio> // remove +#include <fstream> +#include <cmath> +#include <boost/math/special_functions/next.hpp> + +#include <boost/config.hpp> + +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include "test_tools.hpp" + +#include "A.hpp" +#include "A.ipp" + +bool A::check_equal(const A &rhs) const +{ + BOOST_CHECK_EQUAL(b, rhs.b); + BOOST_CHECK_EQUAL(l, rhs.l); + #ifndef BOOST_NO_INT64_T + BOOST_CHECK_EQUAL(f, rhs.f); + BOOST_CHECK_EQUAL(g, rhs.g); + #endif + BOOST_CHECK_EQUAL(m, rhs.m); + BOOST_CHECK_EQUAL(n, rhs.n); + BOOST_CHECK_EQUAL(o, rhs.o); + BOOST_CHECK_EQUAL(p, rhs.p); + BOOST_CHECK_EQUAL(q, rhs.q); + #ifndef BOOST_NO_CWCHAR + BOOST_CHECK_EQUAL(r, rhs.r); + #endif + BOOST_CHECK_EQUAL(c, rhs.c); + BOOST_CHECK_EQUAL(s, rhs.s); + BOOST_CHECK_EQUAL(t, rhs.t); + BOOST_CHECK_EQUAL(u, rhs.u); + BOOST_CHECK_EQUAL(v, rhs.v); + BOOST_CHECK_EQUAL(l, rhs.l); + BOOST_CHECK(std::abs( boost::math::float_distance(w, rhs.w)) < 2); + BOOST_CHECK(std::abs( boost::math::float_distance(x, rhs.x)) < 2); + BOOST_CHECK(!(0 != y.compare(rhs.y))); + #ifndef BOOST_NO_STD_WSTRING + BOOST_CHECK(!(0 != z.compare(rhs.z))); + #endif + return true; +} + +int +test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + A a, a1; + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("a", a); + } + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("a", a1); + } + a.check_equal(a1); + std::remove(testfile); + return 0; +} diff --git a/src/boost/libs/serialization/test/test_simple_class_ptr.cpp b/src/boost/libs/serialization/test/test_simple_class_ptr.cpp new file mode 100644 index 00000000..6d7e95d7 --- /dev/null +++ b/src/boost/libs/serialization/test/test_simple_class_ptr.cpp @@ -0,0 +1,53 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_simple_class_ptr.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <cstddef> // NULL +#include <cstdio> // remove +#include <fstream> + +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include "test_tools.hpp" + +#include "A.hpp" +#include "A.ipp" + +int test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + + BOOST_REQUIRE(NULL != testfile); + + const A *ta = new A(); + A *ta1 = NULL; + + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("ta", ta); + } + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("ta", ta1); + } + BOOST_CHECK(ta != ta1); + BOOST_CHECK(*ta == *ta1); + delete ta; + std::remove(testfile); + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_singleton.cpp b/src/boost/libs/serialization/test/test_singleton.cpp new file mode 100644 index 00000000..822f0b7b --- /dev/null +++ b/src/boost/libs/serialization/test/test_singleton.cpp @@ -0,0 +1,74 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_singleton.cpp + +// (C) Copyright 2018 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <iostream> +#include <boost/serialization/singleton.hpp> + +#include "test_tools.hpp" + +static int i = 0; + +struct A { + int m_id; + A() : m_id(++i) {} + ~A(){ + // verify that objects are destroyed in sequence reverse of construction + if(i-- != m_id) std::terminate(); + } +}; + +struct B { + int m_id; + B() : m_id(++i) {} + ~B(){ + // verify that objects are destroyed in sequence reverse of construction + if(i-- != m_id) std::terminate(); + } +}; + +struct C { + int m_id; + C() : m_id(++i) {} + ~C(){ + // verify that objects are destroyed in sequence reverse of construction + if(i-- != m_id) std::terminate(); + } +}; + +struct D { + int m_id; + D(){ + // verify that only one object is indeed created + const C & c = boost::serialization::singleton<C>::get_const_instance(); + const C & c1 = boost::serialization::singleton<C>::get_const_instance(); + BOOST_CHECK_EQUAL(&c, &c1); + + // verify that objects are created in sequence of definition + BOOST_CHECK_EQUAL(c.m_id, 1); + const B & b = boost::serialization::singleton<B>::get_const_instance(); + BOOST_CHECK_EQUAL(b.m_id, 2); + const A & a = boost::serialization::singleton<A>::get_const_instance(); + BOOST_CHECK_EQUAL(a.m_id, 3); + std::cout << a.m_id << b.m_id << c.m_id << '\n'; + + m_id = ++i; + } + ~D(){ + // verify that objects are destroyed in sequence reverse of construction + if(i-- != m_id) std::terminate(); + } +}; + +int test_main(int, char *[]){ + return 0; +} + +// note: not a singleton +D d; diff --git a/src/boost/libs/serialization/test/test_singleton_inherited.cpp b/src/boost/libs/serialization/test/test_singleton_inherited.cpp new file mode 100644 index 00000000..08164bcf --- /dev/null +++ b/src/boost/libs/serialization/test/test_singleton_inherited.cpp @@ -0,0 +1,81 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_singleton_inherited.cpp: +// Test the singleton class for a "inherited" singleton (used as Foo:public singleton<Foo>) +// This can be uses as singleton<Foo>::get_const_instance() OR Foo::get_const_instance() +// +// - is_destroyed returns false when singleton is active or uninitialized +// - is_destroyed returns true when singleton is destructed +// - the singleton is eventually destructed (no memory leak) + +// (C) Copyright 2018 Alexander Grund +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +#include "test_tools.hpp" +#include <boost/serialization/singleton.hpp> +#include <boost/preprocessor/stringize.hpp> +#include <stdexcept> + +// Can't use BOOST_TEST because: +// a) destructors are called after program exit +// b) This is intended to be used by shared libraries too which would then need their own report_errors call +// We halso have to disable the Wterminate warning as we call this from dtors +// C++ will terminate the program in such cases which is OK here +#pragma GCC diagnostic push +#pragma GCC diagnostic ignored "-Wterminate" +#define THROW_ON_FALSE(cond) if(!(cond)) throw std::runtime_error(__FILE__ "(" BOOST_PP_STRINGIZE(__LINE__) ") Assertion failed: " #cond) + +// Enum to designate the state of the singletonized instances +enum ConstructionState{CS_UNINIT, CS_INIT, CS_DESTROYED}; + +// We need another singleton to check for the destruction of the singletons at program exit +// We don't need all the magic for shared library anti-optimization and can keep it very simple +struct controller{ + static controller& getInstance(){ + static controller instance; + return instance; + } + ConstructionState state; +private: + controller() { + state = CS_UNINIT; + } + ~controller(); +}; + +// A simple class that sets its construction state in the controller singleton +struct Foo: boost::serialization::singleton<Foo>{ + Foo(): i(42) { + // access controller singleton. Therefore controller will be constructed before this + THROW_ON_FALSE(controller::getInstance().state == CS_UNINIT); + controller::getInstance().state = CS_INIT; + } + ~Foo() { + // Because controller is constructed before this, it will be destructed AFTER this. Hence controller is still valid + THROW_ON_FALSE(controller::getInstance().state == CS_INIT); + controller::getInstance().state = CS_DESTROYED; + } + // Volatile to prevent compiler optimization from removing this + volatile int i; +}; + +controller::~controller() { + // If this fails, the singletons were not freed and memory is leaked + THROW_ON_FALSE(state == CS_DESTROYED); + // If this fails, then the destroyed flag is not set and one may use a deleted instance if relying on this flag + THROW_ON_FALSE(boost::serialization::singleton<Foo>::is_destroyed()); + THROW_ON_FALSE(Foo::is_destroyed()); +} + +int +test_main( int /* argc */, char* /* argv */[] ) +{ + // Check if the singleton is alive and use it + BOOST_CHECK(!boost::serialization::singleton<Foo>::is_destroyed()); + BOOST_CHECK(!Foo::is_destroyed()); + + BOOST_CHECK(boost::serialization::singleton<Foo>::get_const_instance().i == 42); + BOOST_CHECK(Foo::get_const_instance().i == 42); + return EXIT_SUCCESS; +} diff --git a/src/boost/libs/serialization/test/test_singleton_plain.cpp b/src/boost/libs/serialization/test/test_singleton_plain.cpp new file mode 100644 index 00000000..7c306141 --- /dev/null +++ b/src/boost/libs/serialization/test/test_singleton_plain.cpp @@ -0,0 +1,77 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_singleton_plain.cpp: +// Test the singleton class for a "plain" singleton (used as singleton<Foo>) +// +// - is_destroyed returns false when singleton is active or uninitialized +// - is_destroyed returns true when singleton is destructed +// - the singleton is eventually destructed (no memory leak) + +// (C) Copyright 2018 Alexander Grund +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +#include "test_tools.hpp" +#include <boost/serialization/singleton.hpp> +#include <boost/preprocessor/stringize.hpp> +#include <stdexcept> + +// Can't use BOOST_TEST because: +// a) destructors are called after program exit +// b) This is intended to be used by shared libraries too which would then need their own report_errors call +// We halso have to disable the Wterminate warning as we call this from dtors +// C++ will terminate the program in such cases which is OK here +#pragma GCC diagnostic push +#pragma GCC diagnostic ignored "-Wterminate" +#define THROW_ON_FALSE(cond) if(!(cond)) throw std::runtime_error(__FILE__ "(" BOOST_PP_STRINGIZE(__LINE__) ") Assertion failed: " #cond) + +// Enum to designate the state of the singletonized instances +enum ConstructionState{CS_UNINIT, CS_INIT, CS_DESTROYED}; + +// We need another singleton to check for the destruction of the singletons at program exit +// We don't need all the magic for shared library anti-optimization and can keep it very simple +struct controller{ + static controller& getInstance(){ + static controller instance; + return instance; + } + ConstructionState state; +private: + controller() { + state = CS_UNINIT; + } + ~controller(); +}; + +// A simple class that sets its construction state in the controller singleton +struct Foo{ + Foo(): i(42) { + // access controller singleton. Therefore controller will be constructed before this + THROW_ON_FALSE(controller::getInstance().state == CS_UNINIT); + controller::getInstance().state = CS_INIT; + } + ~Foo() { + // Because controller is constructed before this, it will be destructed AFTER this. Hence controller is still valid + THROW_ON_FALSE(controller::getInstance().state == CS_INIT); + controller::getInstance().state = CS_DESTROYED; + } + // Volatile to prevent compiler optimization from removing this + volatile int i; +}; + +controller::~controller() { + // If this fails, the singletons were not freed and memory is leaked + THROW_ON_FALSE(state == CS_DESTROYED); + // If this fails, then the destroyed flag is not set and one may use a deleted instance if relying on this flag + THROW_ON_FALSE(boost::serialization::singleton<Foo>::is_destroyed()); +} + +int +test_main( int /* argc */, char* /* argv */[] ) +{ + // Check if the singleton is alive and use it + BOOST_CHECK(!boost::serialization::singleton<Foo>::is_destroyed()); + + BOOST_CHECK(boost::serialization::singleton<Foo>::get_const_instance().i == 42); + return EXIT_SUCCESS; +} diff --git a/src/boost/libs/serialization/test/test_slist.cpp b/src/boost/libs/serialization/test/test_slist.cpp new file mode 100644 index 00000000..3cac92e2 --- /dev/null +++ b/src/boost/libs/serialization/test/test_slist.cpp @@ -0,0 +1,55 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_list.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <cstddef> // NULL +#include <fstream> + +#include <boost/config.hpp> +#include <cstdio> // remove +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include <boost/archive/archive_exception.hpp> +#include "test_tools.hpp" + +#include "A.hpp" +#include "A.ipp" + +#include <boost/serialization/slist.hpp> +void test_slist(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_STD_EXTENSION_NAMESPACE::slist<A> aslist; + aslist.push_front(A()); + aslist.push_front(A()); + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("aslist", aslist); + } + BOOST_STD_EXTENSION_NAMESPACE::slist<A> aslist1;{ + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("aslist", aslist1); + } + BOOST_CHECK(aslist == aslist1); + std::remove(testfile); +} + +int test_main( int /* argc */, char* /* argv */[] ) +{ + test_slist(); + return EXIT_SUCCESS; +} + +// EOF + diff --git a/src/boost/libs/serialization/test/test_slist_ptrs.cpp b/src/boost/libs/serialization/test/test_slist_ptrs.cpp new file mode 100644 index 00000000..3325510a --- /dev/null +++ b/src/boost/libs/serialization/test/test_slist_ptrs.cpp @@ -0,0 +1,88 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_list.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <cstddef> +#include <fstream> + +#include <boost/config.hpp> +#include <cstdio> // remove +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include <boost/type_traits/is_pointer.hpp> +#include <boost/static_assert.hpp> +#include <boost/checked_delete.hpp> + +#include <boost/archive/archive_exception.hpp> +#include "test_tools.hpp" + +#include <boost/serialization/nvp.hpp> + +#include "A.hpp" +#include "A.ipp" + +template<class T> +struct ptr_equal_to { + BOOST_STATIC_ASSERT(::boost::is_pointer< T >::value); + bool operator()(T const _Left, T const _Right) const + { + if(NULL == _Left && NULL == _Right) + return true; + if(typeid(*_Left) != typeid(*_Right)) + return false; + return *_Left == *_Right; + } +}; + +#include <boost/serialization/slist.hpp> +void test_slist(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + BOOST_STD_EXTENSION_NAMESPACE::slist<A *> aslist; + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + aslist.push_front(new A); + aslist.push_front(new A); + oa << boost::serialization::make_nvp("aslist", aslist); + } + BOOST_STD_EXTENSION_NAMESPACE::slist<A *> aslist1; + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("aslist", aslist1); + BOOST_CHECK(aslist.size() == aslist1.size() && + std::equal(aslist.begin(),aslist.end(),aslist1.begin(),ptr_equal_to<A *>()) + ); + } + std::for_each( + aslist.begin(), + aslist.end(), + boost::checked_deleter<A>() + ); + std::for_each( + aslist1.begin(), + aslist1.end(), + boost::checked_deleter<A>() + ); + std::remove(testfile); +} + +int test_main( int /* argc */, char* /* argv */[] ) +{ + test_slist(); + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_smart_cast.cpp b/src/boost/libs/serialization/test/test_smart_cast.cpp new file mode 100644 index 00000000..9cb50aef --- /dev/null +++ b/src/boost/libs/serialization/test/test_smart_cast.cpp @@ -0,0 +1,236 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_smart_cast.cpp: + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) +// <gennadiy.rozental@tfn.com> + +#include <exception> +#include <boost/serialization/smart_cast.hpp> + +#include "test_tools.hpp" +#include <boost/noncopyable.hpp> + +using namespace boost::serialization; + +class Base1 : public boost::noncopyable +{ + char a; +}; + +class Base2 +{ + int b; +}; + +#ifdef BOOST_MSVC +# pragma warning(push) +# pragma warning(disable : 4511 4512) +#endif + +class Derived : public Base1, public Base2 +{ + long c; +}; + +#ifdef BOOST_MSVC +#pragma warning(pop) +#endif + +// if compiler doesn't support TPS, the smart_cast syntax doesn't +// work for references. One has to use the smart_cast_reference +// syntax (tested below ) instead. + +void test_static_reference_cast_2(){ + Derived d; + Base1 & b1 = static_cast<Base1 &>(d); + Base2 & b2 = static_cast<Base2 &>(d); + + Base1 & scb1 = smart_cast<Base1 &, Derived &>(d); + Base2 & scb2 = smart_cast<Base2 &, Derived &>(d); + BOOST_CHECK_EQUAL(& b1, & scb1); + BOOST_CHECK_EQUAL(& b2, & scb2); + + // downcast +// BOOST_CHECK_EQUAL(& d, & (smart_cast<Derived &, Base1 &>(b1))); +// BOOST_CHECK_EQUAL(& d, & (smart_cast<Derived &, Base2 &>(b2))); + + // crosscast pointers fails at compiler time + // BOOST_CHECK_EQUAL(pB2,smart_cast<B2 *>(pB1)); + // though explicit cross cast will always work + BOOST_CHECK_EQUAL(& b2,( + & smart_cast<Base2 &, Derived &>( + smart_cast<Derived &, Base1 &>(b1) + )) + ); +} + +void test_static_reference_cast_1(){ + Derived d; + Base1 & b1 = static_cast<Base1 &>(d); + Base2 & b2 = static_cast<Base2 &>(d); + + Base1 & scb1 = smart_cast_reference<Base1 &>(d); + Base2 & scb2 = smart_cast_reference<Base2 &>(d); + BOOST_CHECK_EQUAL(& b1, & scb1); + BOOST_CHECK_EQUAL(& b2, & scb2); + + // downcast + BOOST_CHECK_EQUAL(& d, & (smart_cast_reference<Derived &>(b1))); + BOOST_CHECK_EQUAL(& d, & (smart_cast_reference<Derived &>(b2))); + + // crosscast pointers fails at compiler time + // BOOST_CHECK_EQUAL(pB2,smart_cast<B2 *>(pB1)); + // though explicit cross cast will always work + BOOST_CHECK_EQUAL(& b2,( + & smart_cast_reference<Base2 &>( + smart_cast_reference<Derived &>(b1) + )) + ); +} + +void test_static_pointer_cast(){ + // pointers + Derived d; + Derived *pD = & d; + Base1 *pB1 = pD; + Base2 *pB2 = pD; + + // upcast + BOOST_CHECK_EQUAL(pB1, smart_cast<Base1 *>(pD)); + BOOST_CHECK_EQUAL(pB2, smart_cast<Base2 *>(pD)); + + // downcast + BOOST_CHECK_EQUAL(pD, smart_cast<Derived *>(pB1)); + BOOST_CHECK_EQUAL(pD, smart_cast<Derived *>(pB2)); + + // crosscast pointers fails at compiler time + // BOOST_CHECK_EQUAL(pB2, smart_cast<Base2 *>(pB1)); + + // though explicit cross cast will always work + BOOST_CHECK_EQUAL(pB2, + smart_cast<Base2 *>( + smart_cast<Derived *>(pB1) + ) + ); +} + +class VBase1 : public boost::noncopyable +{ + char a; +public: + virtual ~VBase1(){}; +}; + +class VBase2 +{ + int b; +public: + virtual ~VBase2(){}; +}; + +#ifdef BOOST_MSVC +# pragma warning(push) +# pragma warning(disable : 4511 4512) +#endif + +class VDerived : public VBase1, public VBase2 +{ + long c; +public: + virtual ~VDerived(){}; +}; + +#ifdef BOOST_MSVC +#pragma warning(pop) +#endif + +// see above + +void test_dynamic_reference_cast_2(){ + VDerived d; + VBase1 &b1 = dynamic_cast<VBase1 &>(d); + VBase2 &b2 = static_cast<VBase2 &>(d); + + VBase1 & vb1 = smart_cast<VBase1 &, VDerived &>(d); + BOOST_CHECK_EQUAL(& b1, & vb1); + BOOST_CHECK_EQUAL(& b2, (& smart_cast<VBase2 &, VDerived &>(d))); + + // downcast + BOOST_CHECK_EQUAL(& d, (& smart_cast<VDerived &, VBase1 &>(b1))); + BOOST_CHECK_EQUAL(& d, (& smart_cast<VDerived &, VBase2 &>(b2))); + + // crosscast + BOOST_CHECK_EQUAL(& b2, (& smart_cast<VBase2 &, VBase1 &>(b1))); + + // explicit cross cast should always work + BOOST_CHECK_EQUAL(& b2, ( + & smart_cast<VBase2 &, VDerived &>( + smart_cast<VDerived &, VBase1 &>(b1) + )) + ); +} + +void test_dynamic_reference_cast_1(){ + VDerived d; + VBase1 &b1 = dynamic_cast<VBase1 &>(d); + VBase2 &b2 = static_cast<VBase2 &>(d); + + VBase1 & vb1 = smart_cast_reference<VBase1 &>(d); + BOOST_CHECK_EQUAL(& b1, & vb1); + BOOST_CHECK_EQUAL(& b2, (& smart_cast_reference<VBase2 &>(d))); + + // downcast + BOOST_CHECK_EQUAL(& d, (& smart_cast_reference<VDerived &>(b1))); + BOOST_CHECK_EQUAL(& d, (& smart_cast_reference<VDerived &>(b2))); + + // crosscast + BOOST_CHECK_EQUAL(& b2, (& smart_cast_reference<VBase2 &>(b1))); + + // explicit cross cast should always work + BOOST_CHECK_EQUAL(& b2, ( + & smart_cast_reference<VBase2 &>( + smart_cast_reference<VDerived &>(b1) + )) + ); +} + +void test_dynamic_pointer_cast(){ + // pointers + VDerived d; + VDerived *pD = & d; + VBase1 *pB1 = pD; + VBase2 *pB2 = pD; + + // upcast + BOOST_CHECK_EQUAL(pB1, smart_cast<VBase1 *>(pD)); + BOOST_CHECK_EQUAL(pB2, smart_cast<VBase2 *>(pD)); + + // downcast + BOOST_CHECK_EQUAL(pD, smart_cast<VDerived *>(pB1)); + BOOST_CHECK_EQUAL(pD, smart_cast<VDerived *>(pB2)); + + // crosscast pointers fails at compiler time + BOOST_CHECK_EQUAL(pB2, smart_cast<VBase2 *>(pB1)); + // though explicit cross cast will always work + BOOST_CHECK_EQUAL(pB2, + smart_cast<VBase2 *>( + smart_cast<VDerived *>(pB1) + ) + ); +} + +int +test_main(int /* argc */, char * /* argv */[]) +{ + test_static_reference_cast_2(); + test_static_reference_cast_1(); + test_static_pointer_cast(); + test_dynamic_reference_cast_2(); + test_dynamic_reference_cast_1(); + test_dynamic_pointer_cast(); + + return EXIT_SUCCESS; +} diff --git a/src/boost/libs/serialization/test/test_split.cpp b/src/boost/libs/serialization/test/test_split.cpp new file mode 100644 index 00000000..98015053 --- /dev/null +++ b/src/boost/libs/serialization/test/test_split.cpp @@ -0,0 +1,165 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_split.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <cstddef> // NULL +#include <cstdio> // remove +#include <fstream> + +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include "test_tools.hpp" + +#include <boost/serialization/split_member.hpp> +#include <boost/serialization/split_free.hpp> + +class A +{ + friend class boost::serialization::access; + template<class Archive> + void save( + Archive & /* ar */, + const unsigned int /* file_version */ + ) const { + ++(const_cast<A &>(*this).count); + } + template<class Archive> + void load( + Archive & /* ar */, + const unsigned int /* file_version */ + ){ + --count; + } + BOOST_SERIALIZATION_SPLIT_MEMBER() + int count; +public: + A() : count(0) {} + ~A() { + BOOST_CHECK(0 == count); + } +}; + +class B +{ + friend class boost::serialization::access; + template<class Archive> + void save( + Archive & /* ar */, + const unsigned int /* file_version */ + ) const { + ++(const_cast<B &>(*this).count); + } + template<class Archive> + void load( + Archive & /* ar */, + const unsigned int /* file_version */ + ){ + --count; + } + int count; +public: + B() : count(0) {} + ~B() { + BOOST_CHECK(0 == count); + } +}; + +// function specializations must be defined in the appropriate +// namespace - boost::serialization +namespace boost { +namespace serialization { + +template<class Archive> +void serialize( + Archive & ar, + B & b, + const unsigned int file_version +){ + boost::serialization::split_member(ar, b, file_version); +} + +} // serialization +} // namespace boost + +class C +{ +public: + int count; + C() : count(0) {} + ~C() { + BOOST_CHECK(0 == count); + } +}; + +namespace boost { +namespace serialization { + +template<class Archive> +void save( + Archive & /* ar */, + const C & c, + const unsigned int /* file_version */ +){ + ++(const_cast<C &>(c).count); +} + +template<class Archive> +void load( + Archive & /* ar */, + C & c, + const unsigned int /* file_version */ +){ + --c.count; +} + +} // serialization +} // namespace boost + +BOOST_SERIALIZATION_SPLIT_FREE(C) + +void out(const char *testfile, A & a, B & b, C & c) +{ + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << BOOST_SERIALIZATION_NVP(a); + oa << BOOST_SERIALIZATION_NVP(b); + oa << BOOST_SERIALIZATION_NVP(c); +} + +void in(const char *testfile, A & a, B & b, C & c) +{ + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> BOOST_SERIALIZATION_NVP(a); + ia >> BOOST_SERIALIZATION_NVP(b); + ia >> BOOST_SERIALIZATION_NVP(c); +} + +int +test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + A a; + B b; + C c; + + out(testfile, a, b, c); + in(testfile, a, b, c); + std::remove(testfile); + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_stack.cpp b/src/boost/libs/serialization/test/test_stack.cpp new file mode 100644 index 00000000..6d54f7b2 --- /dev/null +++ b/src/boost/libs/serialization/test/test_stack.cpp @@ -0,0 +1,56 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_stack.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <cstddef> +#include <fstream> + +#include <cstdio> // remove +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include "test_tools.hpp" + +#include <boost/serialization/nvp.hpp> +#include <boost/serialization/deque.hpp> +#include <boost/serialization/stack.hpp> + +#include "A.hpp" +#include "A.ipp" + +int test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + // test array of objects + std::stack<A, std::deque<A> > astack, astack1; + astack.push(A()); + astack.push(A()); + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("astack",astack); + } + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("astack",astack1); + } + BOOST_CHECK(astack == astack1); + + std::remove(testfile); + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_static_warning.cpp b/src/boost/libs/serialization/test/test_static_warning.cpp new file mode 100644 index 00000000..642b9cf3 --- /dev/null +++ b/src/boost/libs/serialization/test/test_static_warning.cpp @@ -0,0 +1,63 @@ +// (C) Copyright Jonathan Turkanis 2004. +// Use, modification and distribution are subject to the +// Boost Software License, Version 1.0. (See accompanying file +// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for most recent version including documentation. + +// note: this is a compile only test. + +#include <boost/config.hpp> // BOOST_STATIC_CONST +#include <boost/static_assert.hpp> +#include <boost/type_traits/is_polymorphic.hpp> + +#include <boost/serialization/static_warning.hpp> + +typedef char a1[2]; +typedef char a2[3]; + +class polymorphic { + virtual ~polymorphic(); +}; + +class non_polymorphic { +}; + +template<class T> +int f(){ + BOOST_STATIC_WARNING(T::value); + return 0; +} + +struct A { + BOOST_STATIC_CONSTANT(bool, value = false); +}; + +///////////////////////////////////////////////////////////////////////// +// compilation of this program should show a total of 10 warning messages + +// should show NO warning message +BOOST_STATIC_WARNING(true); + +// the following should show 5 warning message +int x = f<A>(); // Warn +int y = f<boost::is_polymorphic<non_polymorphic> >(); // Warn. +int z = f<boost::is_polymorphic<polymorphic> >(); + +BOOST_STATIC_WARNING(sizeof(a1) == sizeof(a2)); // Warn. +BOOST_STATIC_WARNING(sizeof(a1) != sizeof(a1)); // Warn. +BOOST_STATIC_WARNING(! boost::is_polymorphic<polymorphic>::value); // Warn. +BOOST_STATIC_WARNING(boost::is_polymorphic<non_polymorphic>::value); // Warn. + +int main(int /* argc */, char * /* argv */[]){ + // should show NO warning message + BOOST_STATIC_WARNING(true); + + // the following should show 5 warning message + f<A>(); + BOOST_STATIC_WARNING(sizeof(a1) == sizeof(a2)); // Warn. + BOOST_STATIC_WARNING(sizeof(a1) != sizeof(a1)); // Warn. + BOOST_STATIC_WARNING(! boost::is_polymorphic<polymorphic>::value); // Warn. + BOOST_STATIC_WARNING(boost::is_polymorphic<non_polymorphic>::value); // Warn. + return 0; +} diff --git a/src/boost/libs/serialization/test/test_strong_typedef.cpp b/src/boost/libs/serialization/test/test_strong_typedef.cpp new file mode 100644 index 00000000..0dc59c9a --- /dev/null +++ b/src/boost/libs/serialization/test/test_strong_typedef.cpp @@ -0,0 +1,71 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_strong_typedef.cpp + +// (C) Copyright 2016 Ashish Sadanandan +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation +#include <stdlib.h> // EXIT_SUCCESS + +#include <boost/config.hpp> +#include <boost/serialization/strong_typedef.hpp> +#include <boost/static_assert.hpp> + +#include <boost/type_traits/has_nothrow_assign.hpp> +#include <boost/type_traits/has_nothrow_constructor.hpp> +#include <boost/type_traits/has_nothrow_copy.hpp> + +/////////////////////////////////////////////////////////////////////// +// Define a strong typedef for int. +// The new type should be nothrow constructible and assignable. + +BOOST_STRONG_TYPEDEF(int, strong_int) + +#ifndef BOOST_HAS_NOTHROW_CONSTRUCTOR +BOOST_STATIC_ASSERT(boost::has_nothrow_default_constructor<strong_int>::value); +BOOST_STATIC_ASSERT(boost::has_nothrow_copy_constructor<strong_int>::value); +BOOST_STATIC_ASSERT(boost::has_nothrow_assign<strong_int>::value); +#endif + +/////////////////////////////////////////////////////////////////////// +// strong_int can now be placed in another type, which can also be +// nothrow constructible and assignable. + +struct type1 +{ + long some_long; + strong_int sint; +}; + +#ifndef BOOST_HAS_NOTHROW_CONSTRUCTOR +BOOST_STATIC_ASSERT(boost::has_nothrow_default_constructor<type1>::value); +BOOST_STATIC_ASSERT(boost::has_nothrow_copy_constructor<type1>::value); +BOOST_STATIC_ASSERT(boost::has_nothrow_assign<type1>::value); +#endif + +/////////////////////////////////////////////////////////////////////// +// Now define a type that throws, and a strong_typedef for it +// The strong_typedef should also not have nothrow construction/assign. + +struct not_noexcept +{ + not_noexcept() {} + not_noexcept(not_noexcept const&) {} + not_noexcept& operator=(not_noexcept const&) {return *this;} + bool operator==(not_noexcept const&) const {return false;} + bool operator<(not_noexcept const&) const {return false;} +}; +BOOST_STRONG_TYPEDEF(not_noexcept, strong_not_noexcept) + +#ifndef BOOST_HAS_NOTHROW_CONSTRUCTOR +BOOST_STATIC_ASSERT(! boost::has_nothrow_default_constructor<strong_not_noexcept>::value); +BOOST_STATIC_ASSERT(! boost::has_nothrow_copy_constructor<strong_not_noexcept>::value); +BOOST_STATIC_ASSERT(! boost::has_nothrow_assign<strong_not_noexcept>::value); +#endif + +int main() +{ + return EXIT_SUCCESS; +} diff --git a/src/boost/libs/serialization/test/test_tools.hpp b/src/boost/libs/serialization/test/test_tools.hpp new file mode 100644 index 00000000..ed45ee0b --- /dev/null +++ b/src/boost/libs/serialization/test/test_tools.hpp @@ -0,0 +1,264 @@ +#ifndef BOOST_SERIALIZATION_TEST_TOOLS_HPP +#define BOOST_SERIALIZATION_TEST_TOOLS_HPP + +// MS compatible compilers support #pragma once +#if defined(_MSC_VER) +# pragma once +#endif + +#define BOOST_FILESYSTEM_VERSION 3 +#include <boost/filesystem/operations.hpp> // unique_path + +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_tools.hpp +// +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. + +#include <boost/config.hpp> +#ifndef BOOST_NO_EXCEPTION_STD_NAMESPACE + #include <exception> +#endif +#include <boost/detail/no_exceptions_support.hpp> + +#if defined(UNDER_CE) + +// Windows CE does not supply the tmpnam function in its CRT. +// Substitute a primitive implementation here. +namespace boost { +namespace archive { + const char * tmpnam(char * buffer){ + static char ibuffer [512]; + if(NULL == buffer) + buffer = ibuffer; + + static unsigned short index = 0; + std::sprintf(buffer, "\\tmpfile%05X.tmp", index++); + return buffer; + } +} // archive +} // boost + +#elif defined(_WIN32) || defined(__WIN32__) || defined(WIN32) +// win32 has a brain-dead tmpnam implementation. +// which leaves temp files in root directory +// regardless of environmental settings + +#include <cstdlib> +#include <cstring> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; + using ::strcpy; + using ::strcat; + using ::tmpnam; +} +#endif // defined(BOOST_NO_STDC_NAMESPACE) + +#include <direct.h> +#include <boost/archive/tmpdir.hpp> + +//#if defined(__COMO__) + #define chdir _chdir +//#endif // defined win32 + +#if defined(NDEBUG) && defined(__BORLANDC__) + #define STRCPY strcpy +#else + #define STRCPY std::strcpy +#endif + +namespace boost { +namespace archive { + const char * test_filename(const char * dir = NULL, char *fname = NULL){ + static char ibuffer [512]; + ibuffer[0] = '\0'; + if(NULL == dir){ + dir = boost::archive::tmpdir(); + } + STRCPY(ibuffer, dir); + std::strcat(ibuffer, "/"); + if(NULL == fname){ + char old_dir[256]; + _getcwd(old_dir, sizeof(old_dir) - 1); + chdir(dir); + // (C) Copyright 2010 Dean Michael Berris. <mikhailberis@gmail.com> + // Instead of using std::tmpnam, we use Boost.Filesystem's unique_path + boost::filesystem::path tmp_path = + boost::filesystem::unique_path("%%%%%"); + std::strcat(ibuffer, tmp_path.string().c_str()); + chdir(old_dir); + } + else{ + std::strcat(ibuffer, fname); + } + return ibuffer; + } + const char * tmpnam(char * buffer){ + const char * name = test_filename(NULL, NULL); + if(NULL != buffer){ + STRCPY(buffer, name); + } + return name; + } +} // archive +} // boost + +#else // defined(_WIN32) || defined(__WIN32__) || defined(WIN32) +#if defined(__hpux) +// (C) Copyright 2006 Boris Gubenko. +// HP-UX has a restriction that for multi-thread applications, (i.e. +// the ones compiled -mt) if argument to tmpnam is a NULL pointer, then, +// citing the tmpnam(3S) manpage, "the operation is not performed and a +// NULL pointer is returned". tempnam does not have this restriction, so, +// let's use tempnam instead. + +#define tmpnam(X) tempnam(NULL,X) + +namespace boost { +namespace archive { + using ::tmpnam; +} // archive +} // boost + +#else // defined(__hpux) + +// (C) Copyright 2010 Dean Michael Berris. +// Instead of using the potentially dangrous tempnam function that's part +// of the C standard library, on Unix/Linux we use the more portable and +// "safe" unique_path function provided in the Boost.Filesystem library. + +#include <boost/archive/tmpdir.hpp> + +namespace boost { +namespace archive { + char const * tmpnam(char * buffer) { + static char name[512] = {0}; + if (name[0] == 0) { + boost::filesystem::path tempdir(tmpdir()); + boost::filesystem::path tempfilename = + boost::filesystem::unique_path("serialization-%%%%"); + boost::filesystem::path temp = tempdir / tempfilename; + std::strcat(name, temp.string().c_str()); + } + if (buffer != 0) std::strcpy(buffer, name); + return name; + } +} // archive +} // boost + +#endif // defined(__hpux) +#endif // defined(_WIN32) || defined(__WIN32__) || defined(WIN32) + +#include <boost/core/lightweight_test.hpp> + +#define BOOST_CHECK( P ) \ + BOOST_TEST( (P) ) +#define BOOST_REQUIRE( P ) \ + BOOST_TEST( (P) ) +#define BOOST_CHECK_MESSAGE( P, M ) \ + ((P)? (void)0 : ::boost::detail::error_impl( (M) , __FILE__, __LINE__, BOOST_CURRENT_FUNCTION)) +#define BOOST_REQUIRE_MESSAGE( P, M ) \ + BOOST_CHECK_MESSAGE( (P), (M) ) +#define BOOST_CHECK_EQUAL( A , B ) \ + BOOST_TEST( (A) == (B) ) + +namespace boost { namespace detail { +inline void msg_impl(char const * msg, char const * file, int line, char const * function) +{ + std::cerr << file << "(" << line << "): " << msg << " in function '" << function << "'" << std::endl; +} +} } // boost::detail + +#define BOOST_WARN_MESSAGE( P, M ) \ + ((P)? (void)0 : ::boost::detail::msg_impl( (M) , __FILE__, __LINE__, BOOST_CURRENT_FUNCTION)) +#define BOOST_MESSAGE( M ) \ + BOOST_WARN_MESSAGE( true , (M) ) + +#define BOOST_CHECKPOINT( M ) \ + BOOST_WARN_MESSAGE( true , (M) ) + +//#define BOOST_TEST_DONT_PRINT_LOG_VALUE( T ) + +#define BOOST_FAIL( M ) BOOST_REQUIRE_MESSAGE( false, (M) ) +#define EXIT_SUCCESS 0 + +int test_main(int argc, char * argv[]); + +#include <boost/serialization/singleton.hpp> + +int +main(int argc, char * argv[]){ + boost::serialization::get_singleton_module().lock(); + + int retval = 1; + BOOST_TRY{ + retval = test_main(argc, argv); + } + #ifndef BOOST_NO_EXCEPTION_STD_NAMESPACE + BOOST_CATCH(const std::exception & e){ + BOOST_ERROR(e.what()); + } + #endif + BOOST_CATCH(...){ + BOOST_ERROR("failed with uncaught exception:"); + } + BOOST_CATCH_END + + boost::serialization::get_singleton_module().unlock(); + + int error_count = boost::report_errors(); + if(error_count > 0) + retval = error_count; + return retval; +} + +// the following is to ensure that when one of the libraries changes +// BJAM rebuilds and relinks the test. +/* +#include "text_archive.hpp" +#include "text_warchive.hpp" +#include "binary_archive.hpp" +#include "xml_archive.hpp" +#include "xml_warchive.hpp" + +#include "polymorphic_text_archive.hpp" +#include "polymorphic_text_warchive.hpp" +#include "polymorphic_binary_archive.hpp" +#include "polymorphic_xml_archive.hpp" +#include "polymorphic_xml_warchive.hpp" +*/ + +///////////////////////////////////////////// +// invoke header for a custom archive test. + +///////////////////////////////////////////// +// invoke header for a custom archive test. +#if ! defined(BOOST_ARCHIVE_TEST) +#define BOOST_ARCHIVE_TEST text_archive.hpp +#endif + +#include <boost/preprocessor/stringize.hpp> +#include BOOST_PP_STRINGIZE(BOOST_ARCHIVE_TEST) + +#ifndef TEST_STREAM_FLAGS + #define TEST_STREAM_FLAGS (std::ios_base::openmode)0 +#endif + +#ifndef TEST_ARCHIVE_FLAGS + #define TEST_ARCHIVE_FLAGS 0 +#endif + +#ifndef TEST_DIRECTORY +#define TEST_DIRECTORY +#else +#define __x__ TEST_DIRECTORY +#undef TEST_DIRECTORY +#define TEST_DIRECTORY BOOST_PP_STRINGIZE(__x__) +#endif + +#endif // BOOST_SERIALIZATION_TEST_TOOLS_HPP diff --git a/src/boost/libs/serialization/test/test_tracking.cpp b/src/boost/libs/serialization/test/test_tracking.cpp new file mode 100644 index 00000000..9f4b47c0 --- /dev/null +++ b/src/boost/libs/serialization/test/test_tracking.cpp @@ -0,0 +1,130 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_tracking_save.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <cstddef> // NULL +#include <fstream> + +#include <boost/config.hpp> +#include <cstdio> // remove +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include "test_tools.hpp" +#include <boost/serialization/tracking.hpp> +#include <boost/serialization/nvp.hpp> + +#define TEST_CLASS(N, TRACKING) \ +class N \ +{ \ + friend class boost::serialization::access; \ + template<class Archive> \ + void serialize(Archive & /* ar */, const unsigned int /* file_version */){ \ + ++count; \ + } \ +public: \ + static unsigned int count; \ +}; \ +unsigned int N::count = 0;\ +BOOST_CLASS_TRACKING(N, TRACKING) + +TEST_CLASS(AN, ::boost::serialization::track_never) +TEST_CLASS(AS, ::boost::serialization::track_selectively) +TEST_CLASS(AA, ::boost::serialization::track_always) + +// test pointers +TEST_CLASS(PAN, ::boost::serialization::track_never) +TEST_CLASS(PAS, ::boost::serialization::track_selectively) +TEST_CLASS(PAA, ::boost::serialization::track_always) + +void out(const char *testfile) +{ + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + // write object twice to check tracking + AN an; + AS as; + AA aa; + oa << BOOST_SERIALIZATION_NVP(an) << BOOST_SERIALIZATION_NVP(an); + BOOST_CHECK(an.count == 2); + oa << BOOST_SERIALIZATION_NVP(as) << BOOST_SERIALIZATION_NVP(as); + BOOST_CHECK(as.count == 2); + oa << BOOST_SERIALIZATION_NVP(aa) << BOOST_SERIALIZATION_NVP(aa); + BOOST_CHECK(aa.count == 1); + + PAN *pan = new PAN; + PAS *pas = new PAS; + PAA *paa = new PAA; + oa << BOOST_SERIALIZATION_NVP(pan) << BOOST_SERIALIZATION_NVP(pan); + BOOST_CHECK(pan->count == 2); + oa << BOOST_SERIALIZATION_NVP(pas) << BOOST_SERIALIZATION_NVP(pas); + BOOST_CHECK(pas->count == 1); + oa << BOOST_SERIALIZATION_NVP(paa) << BOOST_SERIALIZATION_NVP(paa); + BOOST_CHECK(paa->count == 1); + delete pan; + delete pas; + delete paa; +} + +void in(const char *testfile) +{ + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + // read object twice to check tracking + AN an; + AS as; + AA aa; + + AN::count = 0; + AS::count = 0; + AA::count = 0; + + ia >> BOOST_SERIALIZATION_NVP(an) >> BOOST_SERIALIZATION_NVP(an); + BOOST_CHECK(an.count == 2); + ia >> BOOST_SERIALIZATION_NVP(as) >> BOOST_SERIALIZATION_NVP(as); + BOOST_CHECK(as.count == 2); + ia >> BOOST_SERIALIZATION_NVP(aa) >> BOOST_SERIALIZATION_NVP(aa); + BOOST_CHECK(aa.count == 1); + + PAN::count = 0; + PAS::count = 0; + PAA::count = 0; + + PAN *pan = NULL; + PAS *pas = NULL; + PAA *paa = NULL; + ia >> BOOST_SERIALIZATION_NVP(pan); + ia >> BOOST_SERIALIZATION_NVP(pan); + BOOST_CHECK(pan->count == 2); + ia >> BOOST_SERIALIZATION_NVP(pas); + ia >> BOOST_SERIALIZATION_NVP(pas); + BOOST_CHECK(pas->count == 1); + ia >> BOOST_SERIALIZATION_NVP(paa); + ia >> BOOST_SERIALIZATION_NVP(paa); + BOOST_CHECK(paa->count == 1); + delete pan; + delete pas; + delete paa; +} + +int +test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + out(testfile); + in(testfile); + std::remove(testfile); + return EXIT_SUCCESS; +} + diff --git a/src/boost/libs/serialization/test/test_traits_fail.cpp b/src/boost/libs/serialization/test/test_traits_fail.cpp new file mode 100644 index 00000000..2b8a728f --- /dev/null +++ b/src/boost/libs/serialization/test/test_traits_fail.cpp @@ -0,0 +1,40 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_traits_fail.cpp: test implementation level trait + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// compile test for traits +#include "test_tools.hpp" +#include <boost/serialization/level.hpp> +#include <boost/serialization/version.hpp> + +class A +{ +}; + +BOOST_CLASS_IMPLEMENTATION(A, boost::serialization::not_serializable) +// It can make no sense to assign a version number to a class that +// is not serialized with class information +BOOST_CLASS_VERSION(A, 2) // should fail during compile +// It can make no sense to assign tracking behavior to a class that +// is not serializable. Should fail during compile. +BOOST_CLASS_TRACKING(A, boost::serialization::track_never) + +class B +{ +}; + +BOOST_CLASS_IMPLEMENTATION(B, boost::serialization::object_class_info) +BOOST_CLASS_VERSION(B, 2) +BOOST_CLASS_TRACKING(B, boost::serialization::track_always) + +int +test_main( int /* argc */, char* /* argv */[] ) +{ + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_traits_pass.cpp b/src/boost/libs/serialization/test/test_traits_pass.cpp new file mode 100644 index 00000000..2e650034 --- /dev/null +++ b/src/boost/libs/serialization/test/test_traits_pass.cpp @@ -0,0 +1,30 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_traits_pass.cpp: test implementation level trait + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// compile test for traits +#include "test_tools.hpp" + +#include <boost/serialization/level.hpp> +#include <boost/serialization/tracking.hpp> +#include <boost/serialization/version.hpp> + +class B +{ +}; + +BOOST_CLASS_IMPLEMENTATION(B, boost::serialization::object_class_info) +BOOST_CLASS_VERSION(B, 2) +BOOST_CLASS_TRACKING(B, boost::serialization::track_always) + +int +test_main( int argc, char* argv[] ) +{ + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_unique_ptr.cpp b/src/boost/libs/serialization/test/test_unique_ptr.cpp new file mode 100644 index 00000000..f4f63d5e --- /dev/null +++ b/src/boost/libs/serialization/test/test_unique_ptr.cpp @@ -0,0 +1,70 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_unique_ptr.cpp + +// (C) Copyright 2002-14 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +#include <fstream> +#include <cstdio> // remove, std::auto_ptr interface wrong in dinkumware +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif +#include <boost/serialization/nvp.hpp> + +#include "test_tools.hpp" + +///////////////////////////////////////////////////////////// +// test std::unique_ptr serialization +class A +{ +private: + friend class boost::serialization::access; + int x; + template<class Archive> + void serialize(Archive &ar, const unsigned int /* file_version */){ + ar & BOOST_SERIALIZATION_NVP(x); + } +public: + A(){} // default constructor + ~A(){} // default destructor +}; + +#ifndef BOOST_NO_CXX11_SMART_PTR +#include <boost/serialization/unique_ptr.hpp> + +int test_main(int /* argc */, char * /* argv */[]){ + const char * filename = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != filename); + + // create a new auto pointer to ta new object of type A + std::unique_ptr<A> spa(new A); + { + test_ostream os(filename, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << BOOST_SERIALIZATION_NVP(spa); + } + { + // reset the unique_ptr to NULL + // thereby destroying the object of type A + // note that the reset automagically maintains the reference count + spa.reset(); + test_istream is(filename, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> BOOST_SERIALIZATION_NVP(spa); + std::remove(filename); + } + return EXIT_SUCCESS; +} + +#else + +int test_main(int /* argc */, char * /* argv */[]){ + return EXIT_SUCCESS; +} + +#endif // BOOST_NO_CXX11_SMART_PTR diff --git a/src/boost/libs/serialization/test/test_unregistered.cpp b/src/boost/libs/serialization/test/test_unregistered.cpp new file mode 100644 index 00000000..09cb778d --- /dev/null +++ b/src/boost/libs/serialization/test/test_unregistered.cpp @@ -0,0 +1,313 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_unregistered.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <fstream> + +#include <cstddef> // NULL +#include <cstdio> // remove +#include <cstring> // strcmp +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include "test_tools.hpp" + +#include <boost/archive/archive_exception.hpp> +#include <boost/serialization/base_object.hpp> +#include <boost/serialization/type_info_implementation.hpp> +#include <boost/core/no_exceptions_support.hpp> + +class polymorphic_base +{ + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive & /* ar */, const unsigned int /* file_version */){ + } +public: + virtual ~polymorphic_base(){}; +}; + +class polymorphic_derived1 : public polymorphic_base +{ + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive &ar, const unsigned int /* file_version */){ + ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(polymorphic_base); + } +}; + +class polymorphic_derived2 : public polymorphic_base +{ + friend class boost::serialization::access; + template<class Archive> + void serialize(Archive &ar, const unsigned int /* file_version */){ + ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(polymorphic_base); + } +}; + +struct type1 { + template<typename Archive> + void serialize(Archive&, unsigned int ver) { + BOOST_CHECK(ver == 1); + } +}; +struct type2 { + template<typename Archive> + void serialize(Archive&, unsigned int ver) { + BOOST_CHECK(ver == 2); + } +}; + +BOOST_CLASS_VERSION(type1, 1); +BOOST_CLASS_VERSION(type2, 2); + +// save unregistered polymorphic classes +void save_unregistered1(const char *testfile) +{ + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + + polymorphic_base *rb1 = new polymorphic_derived1; + + // registration IS necessary when serializing a polymorphic class + // through pointer to the base class + bool except = false; + BOOST_TRY { + oa << BOOST_SERIALIZATION_NVP(rb1); + } + BOOST_CATCH(boost::archive::archive_exception const& aex){ + except = true; + } + BOOST_CATCH_END + BOOST_CHECK_MESSAGE(except, "lack of registration not detected !"); + + delete rb1; +} + +// note: the corresponding save function above will not result in +// valid archive - hence, the following code which attempts to load +// and archive will fail. Leave this as a reminder not to do this +#if 0 +// load unregistered polymorphic classes +void load_unregistered1(const char *testfile) +{ + std::ifstream is(testfile); + boost::archive::iarchive ia(is); + + polymorphic_base *rb1(NULL); + + // registration IS necessary when serializing a polymorphic class + // through pointer to the base class + bool except = false; + BOOST_TRY { + ia >> BOOST_SERIALIZATION_NVP(rb1); + } + BOOST_CATCH(boost::archive::archive_exception const& aex){ + except = true; + BOOST_CHECK_MESSAGE( + NULL == rb1, + "failed load resulted in a non-null pointer" + ); + } + BOOST_CATCH_END + BOOST_CHECK_MESSAGE(except, "lack of registration not detected !"); + + delete rb1; +} +#endif + +// save unregistered polymorphic classes +void save_unregistered2(const char *testfile) +{ + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + + polymorphic_derived1 *rd1 = new polymorphic_derived1; + + // registration is NOT necessary when serializing a polymorphic class + // through pointer to a derived class + bool except = false; + BOOST_TRY { + oa << BOOST_SERIALIZATION_NVP(rd1); + } + BOOST_CATCH(boost::archive::archive_exception const& aex){ + except = true; + } + BOOST_CATCH_END + BOOST_CHECK_MESSAGE(! except, "registration not detected !"); + + delete rd1; +} + +// note: the corresponding save function above will not result in +// valid archive - hence, the following code which attempts to load +// and archive will fail. Leave this as a reminder not to do this +// load unregistered polymorphic classes +void load_unregistered2(const char *testfile) +{ + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + + polymorphic_derived1 *rd1 = NULL; + + // registration is NOT necessary when serializing a polymorphic class + // or through pointer to a derived class + bool except = false; + BOOST_TRY { + ia >> BOOST_SERIALIZATION_NVP(rd1); + } + BOOST_CATCH(boost::archive::archive_exception const& aex){ + except = true; + BOOST_CHECK_MESSAGE( + NULL == rd1, + "failed load resulted in a non-null pointer" + ); + } + BOOST_CATCH_END + BOOST_CHECK_MESSAGE(! except, "registration not detected !"); + + delete rd1; +} + +// save registered polymorphic class +void save_registered(const char *testfile) +{ + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + + polymorphic_base *rb1 = new polymorphic_derived1; + polymorphic_base *rb2 = new polymorphic_derived2; + + // registration (forward declaration) will permit correct serialization + // through a pointer to a base class + oa.register_type(static_cast<polymorphic_derived1 *>(NULL)); + oa.register_type(static_cast<polymorphic_derived2 *>(NULL)); + oa << BOOST_SERIALIZATION_NVP(rb1); + oa << BOOST_SERIALIZATION_NVP(rb2); + + delete rb1; + delete rb2; +} + +// load registered polymorphic class +void load_registered(const char *testfile) +{ + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + + polymorphic_base *rb1 = NULL; + polymorphic_base *rb2 = NULL; + + // registration (forward declaration) will permit correct serialization + // through a pointer to a base class + ia.register_type(static_cast<polymorphic_derived1 *>(NULL)); + ia.register_type(static_cast<polymorphic_derived2 *>(NULL)); + + ia >> BOOST_SERIALIZATION_NVP(rb1); + + BOOST_CHECK_MESSAGE(NULL != rb1, "Load resulted in NULL pointer"); + BOOST_CHECK_MESSAGE( + boost::serialization::type_info_implementation< + polymorphic_derived1 + >::type::get_const_instance() + == + * boost::serialization::type_info_implementation< + polymorphic_base + >::type::get_const_instance().get_derived_extended_type_info(*rb1), + "restored pointer b1 not of correct type" + ); + + ia >> BOOST_SERIALIZATION_NVP(rb2); + BOOST_CHECK_MESSAGE(NULL != rb2, "Load resulted in NULL pointer"); + BOOST_CHECK_MESSAGE( + boost::serialization::type_info_implementation< + polymorphic_derived2 + >::type::get_const_instance() + == + * boost::serialization::type_info_implementation< + polymorphic_base + >::type::get_const_instance().get_derived_extended_type_info(*rb2), + "restored pointer b2 not of correct type" + ); + + delete rb1; + delete rb2; +} + +// store a pointer from slot0 +void save_unregistered_pointer(const char *testfile) +{ + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + + oa.register_type(static_cast<type2 *>(NULL)); + + type1 instance1; + type2 *pointer2 = new type2; + + BOOST_TRY { + oa & BOOST_SERIALIZATION_NVP(instance1) & BOOST_SERIALIZATION_NVP(pointer2); + } + BOOST_CATCH(...) { + BOOST_CHECK_MESSAGE(false, "unexpected exception"); + } + BOOST_CATCH_END + + delete pointer2; +} + +// load a pointer from slot0 which has no pointer serializer +void load_unregistered_pointer(const char *testfile) +{ + test_istream is(testfile); + test_iarchive ia(is); + + type1 instance1; + type2 *pointer2(NULL); + + bool except = false; + BOOST_TRY { + ia & BOOST_SERIALIZATION_NVP(instance1) & BOOST_SERIALIZATION_NVP(pointer2); + } + BOOST_CATCH(boost::archive::archive_exception const& aex){ + except = true; + BOOST_CHECK_MESSAGE( + std::strcmp(aex.what(), "unregistered class") == 0, + "incorrect exception" + ); + } + BOOST_CATCH_END + BOOST_CHECK_MESSAGE(except, "lack of registration not detected !"); + BOOST_CHECK_MESSAGE(NULL == pointer2, "expected failed load"); + + delete pointer2; +} + +int +test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + save_unregistered1(testfile); +// load_unregistered1(testfile); + save_unregistered2(testfile); + load_unregistered2(testfile); + save_registered(testfile); + load_registered(testfile); + save_unregistered_pointer(testfile); + load_unregistered_pointer(testfile); + std::remove(testfile); + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_valarray.cpp b/src/boost/libs/serialization/test/test_valarray.cpp new file mode 100644 index 00000000..391f59f5 --- /dev/null +++ b/src/boost/libs/serialization/test/test_valarray.cpp @@ -0,0 +1,56 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_valarrray.cpp + +// (C) Copyright 2005 Matthias Troyer . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <cstddef> // NULL +#include <fstream> + +#include <cstdio> // remove +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include "test_tools.hpp" + +#include <boost/serialization/valarray.hpp> + +int test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + // test array of objects + std::valarray<int> avalarray(2); + avalarray[0] = 42; + avalarray[1] = -42; + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("avalarray", avalarray); + } + std::valarray<int> avalarray1; + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("avalarray", avalarray1); + } + bool equal = ( avalarray.size() == avalarray1.size() + && avalarray[0] == avalarray1[0] + && avalarray[1] == avalarray1[1] + ); + + BOOST_CHECK(equal); + std::remove(testfile); + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_variant.cpp b/src/boost/libs/serialization/test/test_variant.cpp new file mode 100644 index 00000000..395def61 --- /dev/null +++ b/src/boost/libs/serialization/test/test_variant.cpp @@ -0,0 +1,299 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_variant.cpp +// test of non-intrusive serialization of variant types +// +// copyright (c) 2005 +// troy d. straszheim <troy@resophonic.com> +// http://www.resophonic.com +// +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) +// +// See http://www.boost.org for updates, documentation, and revision history. +// +// thanks to Robert Ramey and Peter Dimov. +// + +#include <cstddef> // NULL +#include <cstdio> // remove +#include <fstream> +#include <boost/config.hpp> +#include <boost/math/special_functions/next.hpp> // float_distance +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include <boost/type_traits/is_same.hpp> +#include <boost/mpl/eval_if.hpp> +#include <boost/mpl/identity.hpp> +#include <boost/serialization/throw_exception.hpp> + +#if defined(_MSC_VER) && (_MSC_VER <= 1020) +# pragma warning (disable : 4786) // too long name, harmless warning +#endif + +#include "test_tools.hpp" + +#include <boost/archive/archive_exception.hpp> + +#include <boost/serialization/nvp.hpp> +#include <boost/serialization/variant.hpp> + +#include "A.hpp" +#include "A.ipp" + +class are_equal + : public boost::static_visitor<bool> +{ +public: + // note extra rigamorole for compilers which don't support + // partial function template ordering - specfically msvc 6.x + struct same { + template<class T, class U> + static bool invoke(const T & t, const U & u){ + return t == u; + } + }; + + struct not_same { + template<class T, class U> + static bool invoke(const T &, const U &){ + return false; + } + }; + + template <class T, class U> + bool operator()( const T & t, const U & u) const + { + typedef typename boost::mpl::eval_if<boost::is_same<T, U>, + boost::mpl::identity<same>, + boost::mpl::identity<not_same> + >::type type; + return type::invoke(t, u); + } + + bool operator()( const float & lhs, const float & rhs ) const + { + return std::abs( boost::math::float_distance(lhs, rhs)) < 2; + } + bool operator()( const double & lhs, const double & rhs ) const + { + return std::abs( boost::math::float_distance(lhs, rhs)) < 2; + } +}; + +template <class T> +void test_type(const T& gets_written){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(testfile != NULL); + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("written", gets_written); + } + + T got_read; + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("written", got_read); + } + BOOST_CHECK(boost::apply_visitor(are_equal(), gets_written, got_read)); + + std::remove(testfile); +} + +// this verifies that if you try to read in a variant from a file +// whose "which" is illegal for the one in memory (that is, you're +// reading in to a different variant than you wrote out to) the load() +// operation will throw. One could concievably add checking for +// sequence length as well, but this would add size to the archive for +// dubious benefit. +// +void do_bad_read() +{ + // Compiling this test invokes and ICE on msvc 6 + // So, we'll just to skip it for this compiler + #if defined(_MSC_VER) && (_MSC_VER <= 1020) + boost::variant<bool, float, int, std::string> big_variant; + big_variant = std::string("adrenochrome"); + + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(testfile != NULL); + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << BOOST_SERIALIZATION_NVP(big_variant); + } + boost::variant<bool, float, int> little_variant; + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + bool exception_invoked = false; + BOOST_TRY { + ia >> BOOST_SERIALIZATION_NVP(little_variant); + } BOOST_CATCH (boost::archive::archive_exception const& e) { + BOOST_CHECK(boost::archive::archive_exception::unsupported_version == e.code); + exception_invoked = true; + } + BOOST_CATCH_END + BOOST_CHECK(exception_invoked); + } + #endif +} + +struct H { + int i; +}; + +namespace boost { +namespace serialization { + +template<class Archive> +void serialize(Archive &ar, H & h, const unsigned int /*file_version*/){ + ar & boost::serialization::make_nvp("h", h.i); +} + +} // namespace serialization +} // namespace boost + +inline bool operator==(H const & lhs, H const & rhs) { + return lhs.i == rhs.i; +} + +inline bool operator!=(H const & lhs, H const & rhs) { + return !(lhs == rhs); +} + +inline bool operator<(H const & lhs, H const & rhs) { + return lhs.i < rhs.i; +} + +inline std::size_t hash_value(H const & val) { + return val.i; +} + +void test_pointer(){ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(testfile != NULL); + typedef boost::variant<H, int> variant_t; + H const h = {5}; + variant_t v(h); + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("written", v); + const H * h_ptr = & boost::strict_get<H const &>(v); + oa << boost::serialization::make_nvp("written", h_ptr); + } + variant_t v2; + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("written", v2); + H * h2_ptr; + ia >> boost::serialization::make_nvp("written", h2_ptr); + BOOST_CHECK_EQUAL(h, boost::strict_get<H const>(v2)); + BOOST_CHECK_EQUAL(h2_ptr, & boost::strict_get<H const &>(v2)); + } + BOOST_CHECK_EQUAL(v, v2); +} + +#include <boost/serialization/map.hpp> +#include <boost/serialization/set.hpp> + +// test a pointer to an object contained into a variant that is an +// element of a set +void test_variant_set() +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(testfile != NULL); + typedef boost::variant<H, int> variant_t; + typedef std::set<variant_t> uset_t; + uset_t set; + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + H const h = {5}; + variant_t v(h); + set.insert(v); + oa << boost::serialization::make_nvp("written", set); + H const * const h_ptr = boost::strict_get<H const>(&(*set.begin())); + oa << boost::serialization::make_nvp("written", h_ptr); + } + uset_t set2; + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("written", set2); + H * h_ptr; + ia >> boost::serialization::make_nvp("written", h_ptr); + const H * h_ptr2 = & boost::strict_get<H const>(*set2.begin()); + BOOST_CHECK_EQUAL(h_ptr, h_ptr2); + } + BOOST_CHECK_EQUAL(set, set2); +} + +// test a pointer to an object contained into a variant that is an +// element of a map +void test_variant_map() +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(testfile != NULL); + typedef boost::variant<H, int> variant_t; + typedef std::map<int, variant_t> map_t; + map_t map; + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + H const h = {5}; + variant_t v(h); + map[0] = v; + BOOST_ASSERT(1 == map.size()); + oa << boost::serialization::make_nvp("written", map); + H const * const h_ptr = boost::strict_get<H const>(&map[0]); + BOOST_CHECK_EQUAL(h_ptr, boost::strict_get<H const>(&map[0])); + oa << boost::serialization::make_nvp("written", h_ptr); + } + map_t map2; + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("written", map2); + BOOST_ASSERT(1 == map2.size()); + H * h_ptr; + ia >> boost::serialization::make_nvp("written", h_ptr); + H const * const h_ptr2 = boost::strict_get<H const>(&map2[0]); + BOOST_CHECK_EQUAL(h_ptr, h_ptr2); + } + BOOST_CHECK_EQUAL(map, map2); +} + +int test_main( int /* argc */, char* /* argv */[] ) +{ + { + boost::variant<bool, int, float, double, A, std::string> v; + v = false; + test_type(v); + v = 1; + test_type(v); + v = (float) 2.3; + test_type(v); + v = (double) 6.4; + test_type(v); + v = std::string("we can't stop here, this is Bat Country"); + test_type(v); + v = A(); + test_type(v); + } + test_pointer(); + test_variant_set(); + test_variant_map(); + do_bad_read(); + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_vector.cpp b/src/boost/libs/serialization/test/test_vector.cpp new file mode 100644 index 00000000..130ddab4 --- /dev/null +++ b/src/boost/libs/serialization/test/test_vector.cpp @@ -0,0 +1,128 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_vector.cpp + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <cstddef> // NULL +#include <fstream> + +#include <cstdio> // remove +#include <boost/config.hpp> +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif +#include <boost/static_assert.hpp> +#include "test_tools.hpp" + +#include <boost/serialization/vector.hpp> + +// normal class with default constructor +#include "A.hpp" +#include "A.ipp" + +template <class T> +int test_vector_detail(const std::vector<T> & avector) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + // test array of objects + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + oa << boost::serialization::make_nvp("avector", avector); + } + std::vector< T > avector1; + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("avector", avector1); + } + BOOST_CHECK(avector == avector1); + std::remove(testfile); + return EXIT_SUCCESS; +} + +template <class T> +int test_default_constructible() +{ + // test array of objects + std::vector<T> avector; + avector.push_back(T()); + avector.push_back(T()); + return test_vector_detail(avector); +} + +// class without default constructor +struct X { + //BOOST_DELETED_FUNCTION(X()); +public: + int m_i; + X(const X & x) : + m_i(x.m_i) + {} + X(const int & i) : + m_i(i) + {} + bool operator==(const X & rhs) const { + return m_i == rhs.m_i; + } + template<class Archive> + void serialize(Archive & ar, const unsigned int /*version*/){ + ar & BOOST_SERIALIZATION_NVP(m_i); + } +}; + +template<class Archive> +inline void save_construct_data( + Archive & ar, + const X * x, + const unsigned int /* file_version */ +){ + // variable used for construction + ar << boost::serialization::make_nvp("i", x->m_i); +} + +template<class Archive> +inline void load_construct_data( + Archive & ar, + X * x, + const unsigned int /* file_version */ +){ + int i; + ar >> boost::serialization::make_nvp("i", i); + ::new(x)X(i); +} + +int test_non_default_constructible() +{ + // test array of objects + std::vector<X> avector; + avector.push_back(X(123)); + avector.push_back(X(456)); + return test_vector_detail(avector); +} + +int test_main( int /* argc */, char* /* argv */[] ) +{ + int res; + res = test_default_constructible<A>(); + // test an int vector for which optimized versions should be available + if (res == EXIT_SUCCESS) + res = test_default_constructible<int>(); + // test a bool vector + if (res == EXIT_SUCCESS) + res = test_default_constructible<bool>(); + if (res == EXIT_SUCCESS) + res = test_non_default_constructible(); + return res; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_void_cast.cpp b/src/boost/libs/serialization/test/test_void_cast.cpp new file mode 100644 index 00000000..8fdd6d8d --- /dev/null +++ b/src/boost/libs/serialization/test/test_void_cast.cpp @@ -0,0 +1,165 @@ +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_void_cast.cpp: test implementation of run-time casting of void pointers + +// (C) Copyright 2002 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) +// <gennadiy.rozental@tfn.com> + +#include <cstddef> // NULL +#include "test_tools.hpp" +#include <boost/serialization/extended_type_info_typeid.hpp> +#include <boost/serialization/void_cast.hpp> +#include <boost/serialization/singleton.hpp> + +class Base1 +{ + char a; +}; + +class Base2 +{ + int b; +}; + +class Derived : public Base1, public Base2 +{ + long c; +}; + +class MostDerived : public Derived +{ + char d[32]; +}; + +template<class T> +const boost::serialization::extended_type_info & eti(){ + return boost::serialization::singleton< + boost::serialization::extended_type_info_typeid< T > + >::get_const_instance(); +} + +int +test_main( int /* argc */, char* /* argv */[] ) +{ + MostDerived md; + MostDerived* pmd =& md; + Derived* pd = static_cast<Derived*>(pmd); + + Base2* pb2 = static_cast<Base2*>(pmd); + Base1* pb1 = static_cast<Base1*>(pd); + + void* vpmd = static_cast<void*>(pmd); + void* vpb1 = static_cast<void*>(pb1); + void* vpb2 = static_cast<void*>(pb2); + void* vpd = static_cast<void*>(pd); + + // simple casts only requiring table lookup + BOOST_CHECK(vpd == boost::serialization::void_downcast( + eti<Derived>(), + eti<Base1>(), + vpb1 + )); + BOOST_CHECK(vpb1 == boost::serialization::void_upcast( + eti<Derived>(), + eti<Base1>(), + vpd + )); + BOOST_CHECK(vpd == boost::serialization::void_downcast( + eti<Derived>(), + eti<Base2>(), + vpb2 + )); + BOOST_CHECK(vpb2 == boost::serialization::void_upcast( + eti<Derived>(), + eti<Base2>(), + vpd + )); + BOOST_CHECK(vpmd == boost::serialization::void_downcast( + eti<MostDerived>(), + eti<Derived>(), + vpd + )); + BOOST_CHECK(vpd == boost::serialization::void_upcast( + eti<MostDerived>(), + eti<Derived>(), + vpmd + )); + // note relationship between MostDerived and Base1 is automatically derived + BOOST_CHECK(vpmd == boost::serialization::void_downcast( + eti<MostDerived>(), + eti<Base1>(), + vpb1 + )); + BOOST_CHECK(vpb1 == boost::serialization::void_upcast( + eti<MostDerived>(), + eti<Base1>(), + vpmd + )); + + // note relationship between MostDerived and Base2 is automatically derived + BOOST_CHECK(vpmd == boost::serialization::void_downcast( + eti<MostDerived>(), + eti<Base2>(), + vpb2 + )); + BOOST_CHECK(vpb2 == boost::serialization::void_upcast( + eti<MostDerived>(), + eti<Base2>(), + vpmd + )); + + // note: currently derivations are not optimised. See void_cast.cpp + // for and explanation. These should still work though. + + // need to double check to validate speed up optimization of derivations + BOOST_CHECK(vpmd == boost::serialization::void_downcast( + eti<MostDerived>(), + eti<Base1>(), + vpb1 + )); + BOOST_CHECK(vpb1 == boost::serialization::void_upcast( + eti<MostDerived>(), + eti<Base1>(), + vpmd + )); + BOOST_CHECK(vpmd == boost::serialization::void_downcast( + eti<MostDerived>(), + eti<Base2>(), + vpb2 + )); + BOOST_CHECK(vpb2 == boost::serialization::void_upcast( + eti<MostDerived>(), + eti<Base2>(), + vpmd + )); + + // check things that should fail + BOOST_CHECK(NULL == boost::serialization::void_downcast( + eti<Base2>(), + eti<Base1>(), + vpb1 + )); + + // note that a fundamental feature is that derived/base pairs are created + // at compiler time so that all are registered before the main program starts + // so leave the registration here at the end to verify this. Note bogus arguments + // to workaround msvc 6 bug + boost::serialization::void_cast_register<Derived, Base1>( + static_cast<Derived *>(NULL), + static_cast<Base1 *>(NULL) + ); + boost::serialization::void_cast_register<Derived, Base2>( + static_cast<Derived *>(NULL), + static_cast<Base2 *>(NULL) + ); + boost::serialization::void_cast_register<MostDerived, Derived>( + static_cast<MostDerived *>(NULL), + static_cast<Derived *>(NULL) + ); + + return EXIT_SUCCESS; +} + +// EOF diff --git a/src/boost/libs/serialization/test/test_z.cpp b/src/boost/libs/serialization/test/test_z.cpp new file mode 100644 index 00000000..b3f7c13f --- /dev/null +++ b/src/boost/libs/serialization/test/test_z.cpp @@ -0,0 +1,704 @@ +#if 0 +#include <stdexcept> +#include <iostream> +#include <sstream> + +#include <boost/optional.hpp> +#include <boost/archive/text_oarchive.hpp> +#include <boost/archive/text_iarchive.hpp> +#include <boost/serialization/optional.hpp> + +struct Foo +{ + Foo(int aBar) : + mBar(aBar) + { + if (mBar > 10) + { + throw std::logic_error("too big bar"); + } + } + int bar() const + { + return mBar; + } + bool operator==(const Foo & rhs) const { + return mBar == rhs.mBar; + } +private: + int mBar; +}; + +namespace boost { +namespace serialization { + +template<class Archive> +inline void serialize(Archive & ar, Foo& foo, const unsigned int /*version*/) +{ + std::cout << __FUNCTION__ << " called" << std::endl; +} + +template<class Archive> +inline void save_construct_data(Archive & ar, const Foo* foo, const unsigned int /*version*/) +{ + std::cout << __FUNCTION__ << " called" << std::endl; + ar & foo->bar(); +} + +template<class Archive> +inline void load_construct_data(Archive & ar, Foo* foo, const unsigned int /*version*/) +{ + std::cout << __FUNCTION__ << " called" << std::endl; + int bar; + ar & bar; + ::new(foo) Foo(bar); +} + +} // serialization +} // boost + + +int main() +{ + boost::optional<Foo> oldFoo = Foo(10); + std::ostringstream outStream; + boost::archive::text_oarchive outArchive(outStream); + outArchive & oldFoo; + + boost::optional<Foo> newFoo; + std::istringstream inStream(outStream.str()); + boost::archive::text_iarchive inArchive(inStream); + inArchive & newFoo; + + return !(newFoo == oldFoo); +} + +#elif 0 +/////////1/////////2/////////3/////////4/////////5/////////6/////////7/////////8 +// test_optional.cpp + +// (C) Copyright 2004 Pavel Vozenilek +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// should pass compilation and execution + +#include <cstddef> // NULL +#include <cstdio> // remove +#include <fstream> + +#include <boost/config.hpp> + +#if defined(BOOST_NO_STDC_NAMESPACE) +namespace std{ + using ::remove; +} +#endif + +#include <boost/archive/archive_exception.hpp> + +#define BOOST_ARCHIVE_TEST xml_archive.hpp + +#include "test_tools.hpp" + +#include <boost/serialization/optional.hpp> + +#include "A.hpp" +#include "A.ipp" + +int test_main( int /* argc */, char* /* argv */[] ) +{ + const char * testfile = boost::archive::tmpnam(NULL); + BOOST_REQUIRE(NULL != testfile); + + const boost::optional<int> aoptional1; + const boost::optional<int> aoptional2(123); + { + test_ostream os(testfile, TEST_STREAM_FLAGS); + test_oarchive oa(os, TEST_ARCHIVE_FLAGS); + //oa << boost::serialization::make_nvp("aoptional1",aoptional1); + //oa << boost::serialization::make_nvp("aoptional2",aoptional2); + } + /* + boost::optional<int> aoptional1a(999); + boost::optional<int> aoptional2a; + { + test_istream is(testfile, TEST_STREAM_FLAGS); + test_iarchive ia(is, TEST_ARCHIVE_FLAGS); + ia >> boost::serialization::make_nvp("aoptional1",aoptional1a); + ia >> boost::serialization::make_nvp("aoptional2",aoptional2a); + } + BOOST_CHECK(aoptional1 == aoptional1a); + BOOST_CHECK(aoptional2 == aoptional2a); + */ + std::remove(testfile); + return EXIT_SUCCESS; +} + +// EOF + +#elif 0 + +#include <fstream> + +#include <boost/archive/xml_woarchive.hpp> +#include <boost/archive/xml_wiarchive.hpp> +#include <boost/serialization/string.hpp> + +#include "test_tools.hpp" + +int test_main(int, char *argv[]) +{ + const char * testfile = boost::archive::tmpnam(NULL); + std::string s1 = "kkkabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyz"; + std::wstring w1 = L"kkk"; + std::wstring w2 = L"апр"; // some non-latin (for example russians) letters + { + std::wofstream ofs(testfile); + { + boost::archive::xml_woarchive oa(ofs); + oa << boost::serialization::make_nvp("key1", s1); + //oa << boost::serialization::make_nvp("key2", w1); + //oa << boost::serialization::make_nvp("key3", w2); // here exception is thrown + } + } + std::string new_s1; + //std::wstring new_w1; + //std::wstring new_w2; + { + std::wifstream ifs(testfile); + { + boost::archive::xml_wiarchive ia(ifs); + ia >> boost::serialization::make_nvp("key1", new_s1); + //ia >> boost::serialization::make_nvp("key2", new_w1); + //ia >> boost::serialization::make_nvp("key3", new_w2); // here exception is thrown + } + } + BOOST_CHECK(s1 == new_s1); + //BOOST_CHECK(w1 == new_w1); + //BOOST_CHECK(w2 == new_w2); + return 0; +} + +#elif 0 + +#include <boost/archive/xml_oarchive.hpp> +#include <boost/serialization/nvp.hpp> + +#include <iostream> + +int main() { + boost::archive::xml_oarchive oa( std::cerr ); + int bob = 3; + oa << boost::serialization::make_nvp( "bob", bob ); +} + +#elif 0 + +#include <fstream> +#include <vector> +#include <iostream> + +//#include <boost/shared_ptr.hpp> +#include <boost/archive/binary_iarchive.hpp> +#include <boost/serialization/nvp.hpp> +#include <boost/serialization/shared_ptr.hpp> +#include <boost/serialization/vector.hpp> + +struct boxed_int +{ + boxed_int() : i(0) {} + boxed_int(int i) : i(i) {} + int i; + template<class Archive> + void serialize(Archive &ar, unsigned version) + { + ar & BOOST_SERIALIZATION_NVP(i); + } +}; +typedef boost::shared_ptr<boxed_int> pi; + +void go(std::istream &is) { + std::vector<pi> vv; + try + { + boost::archive::binary_iarchive ia(is); + ia & vv; + } + catch(std::exception &e) {} +} + +int main(int argc, char **argv) { + if(argc > 1) { + std::ifstream is(argv[1]); + go(is); + } else { + go(std::cin); + } + + return 0; +} + +#elif 0 + +#include <cassert> +#include <string> + +#include <boost/archive/iterators/base64_from_binary.hpp> +#include <boost/archive/iterators/transform_width.hpp> + +namespace bai = boost::archive::iterators; +int main() +{ + std::string input = + "A large rose-tree stood near the entrance of the garden: the roses growing on it were white, but there were " + "three gardeners at it, busily painting them red. Alice thought this a very curious thing, and she went nearer " + "to watch them, and just as she came up to them she heard one of them say, 'Look out now, Five! Don't go " + "splashing paint over me like that!''I couldn't help it,' said Five, in a sulky tone; 'Seven jogged my " + "elbow.'On which Seven looked up and said, 'That's right, Five! Always lay the blame on others!''You'd better " + "not talk!' said Five. 'I heard the Queen say only yesterday you deserved to be beheaded!''What for?' said the " + "one who had spoken first.'That's none of your business, Two!' said Seven.'Yes, it is his business!' said " + "Five, 'and I'll tell him—it was for bringing the cook tulip-roots instead of onions.'Seven flung down his " + "brush, and had just begun 'Well, of all the unjust things—' when his eye chanced to fall upon Alice, as she " + "stood watching them, and he checked himself suddenly: the others looked round also, and all of them bowed " + "low.'Would you tell me,' said Alice, a little timidly, 'why you are painting those roses?'Five and Seven said " + "nothing, but looked at Two. Two began in a low voice, 'Why the fact is, you see, Miss, this here ought to " + "have been a red rose-tree, and we put a white one in by mistake; and if the Queen was to find it out, we " + "should all have our heads cut off, you know. So you see, Miss, we're doing our best, afore she comes, to—' At " + "this moment Five, who had been anxiously looking across the garden, called out 'The Queen! The Queen!' and " + "the three gardeners instantly threw themselves flat upon their faces. There was a sound of many footsteps, " + "and Alice looked round, eager to see the Queen.First came ten soldiers carrying clubs; these were all shaped " + "like the three gardeners, oblong and flat, with their hands and feet at the corners: next the ten courtiers; " + "these were ornamented all over with diamonds, and walked two and two, as the soldiers did. After these came " + "the royal children; there were ten of them, and the little dears came jumping merrily along hand in hand, in " + "couples: they were all ornamented with hearts. Next came the guests, mostly Kings and Queens, and among them " + "Alice recognised the White Rabbit: it was talking in a hurried nervous manner, smiling at everything that was " + "said, and went by without noticing her. Then followed the Knave of Hearts, carrying the King's crown on a " + "crimson velvet cushion; and, last of all this grand procession, came THE KING AND QUEEN OF HEARTS.Alice was " + "rather doubtful whether she ought not to lie down on her face like the three gardeners, but she could not " + "remember ever having heard of such a rule at processions; 'and besides, what would be the use of a " + "procession,' thought she, 'if people had all to lie down upon their faces, so that they couldn't see it?' So " + "she stood still where she was, and waited.When the procession came opposite to Alice, they all stopped and " + "looked at her, and the Queen said severely 'Who is this?' She said it to the Knave of Hearts, who only bowed " + "and smiled in reply.'Idiot!' said the Queen, tossing her head impatiently; and, turning to Alice, she went " + "on, 'What's your name, child?''My name is Alice, so please your Majesty,' said Alice very politely; but she " + "added, to herself, 'Why, they're only a pack of cards, after all. I needn't be afraid of them!''And who are " + "these?' said the Queen, pointing to the three gardeners who were lying round the rosetree; for, you see, as " + "they were lying on their faces, and the pattern on their backs was the same as the rest of the pack, she " + "could not tell whether they were gardeners, or soldiers, or courtiers, or three of her own children.'How " + "should I know?' said Alice, surprised at her own courage. 'It's no business of mine.'The Queen turned crimson " + "with fury, and, after glaring at her for a moment like a wild beast, screamed 'Off with her head! " + "Off—''Nonsense!' said Alice, very loudly and decidedly, and the Queen was silent.The King laid his hand upon " + "her arm, and timidly said 'Consider, my dear: she is only a child!'The Queen turned angrily away from him, " + "and said to the Knave 'Turn them over!'The Knave did so, very carefully, with one foot.'Get up!' said the " + "Queen, in a shrill, loud voice, and the three gardeners instantly jumped up, and began bowing to the King, " + "the Queen, the royal children, and everybody else.'Leave off that!' screamed the Queen. 'You make me giddy.' " + "And then, turning to the rose-tree, she went on, 'What have you been doing here?''May it please your " + "Majesty,' said Two, in a very humble tone, going down on one knee as he spoke, 'we were trying—''I see!' said " + "the Queen, who had meanwhile been examining the roses. 'Off with their heads!' and the procession moved on, " + "three of the soldiers remaining behind to execute the unfortunate gardeners, who ran to Alice for " + "protection.'You shan't be beheaded!' said Alice, and she put them into a large flower-pot that stood near. " + "The three soldiers wandered about for a minute or two, looking for them, and then quietly marched off after " + "the others.'Are their heads off?' shouted the Queen.'Their heads are gone, if it please your Majesty!' the " + "soldiers shouted in reply.'That's right!' shouted the Queen. 'Can you play croquet?'The soldiers were silent, " + "and looked at Alice, as the question was evidently meant for her.'Yes!' shouted Alice.'Come on, then!' roared " + "the Queen, and Alice joined the procession, wondering very much what would happen next.'It's—it's a very fine " + "day!' said a timid voice at her side. She was walking by the White Rabbit, who was peeping anxiously into her " + "face.'Very,' said Alice: '—where's the Duchess?''Hush! Hush!' said the Rabbit in a low, hurried tone. He " + "looked anxiously over his shoulder as he spoke, and then raised himself upon tiptoe, put his mouth close to " + "her ear, and whispered 'She's under sentence of execution.''What for?' said Alice.'Did you say \"What a " + "pity!\"?' the Rabbit asked.'No, I didn't,' said Alice: 'I don't think it's at all a pity. I said \"What " + "for?\"''She boxed the Queen's ears—' the Rabbit began. Alice gave a little scream of laughter. 'Oh, hush!' " + "the Rabbit whispered in a frightened tone. 'The Queen will hear you! You see, she came rather late, and the " + "Queen said—''Get to your places!' shouted the Queen in a voice of thunder, and people began running about in " + "all directions, tumbling up against each other; however, they got settled down in a minute or two, and the " + "game began. Alice thought she had never seen such a curious croquet-ground in her life; it was all ridges and " + "furrows; the balls were live hedgehogs, the mallets live flamingoes, and the soldiers had to double " + "themselves up and to stand on their hands and feet, to make the arches.The chief difficulty Alice found at " + "first was in managing her flamingo: she succeeded in getting its body tucked away, comfortably enough, under " + "her arm, with its legs hanging down, but generally, just as she had got its neck nicely straightened out, and " + "was going to give the hedgehog a blow with its head, it would twist itself round and look up in her face, " + "with such a puzzled expression that she could not help bursting out laughing: and when she had got its head " + "down, and was going to begin again, it was very provoking to find that the hedgehog had unrolled itself, and " + "was in the act of crawling away: besides all this, there was generally a ridge or furrow in the way wherever " + "she wanted to send the hedgehog to, and, as the doubled-up soldiers were always getting up and walking off to " + "other parts of the ground, Alice soon came to the conclusion that it was a very difficult game indeed.The " + "players all played at once without waiting for turns, quarrelling all the while, and fighting for the " + "hedgehogs; and in a very short time the Queen was in a furious passion, and went stamping about, and shouting " + "'Off with his head!' or 'Off with her head!' about once in a minute.Alice began to feel very uneasy: to be " + "sure, she had not as yet had any dispute with the Queen, but she knew that it might happen any minute, 'and " + "then,' thought she, 'what would become of me? They're dreadfully fond of beheading people here; the great " + "wonder is, that there's any one left alive!'She was looking about for some way of escape, and wondering " + "whether she could get away without being seen, when she noticed a curious appearance in the air: it puzzled " + "her very much at first, but, after watching it a minute or two, she made it out to be a grin, and she said to " + "herself 'It's the Cheshire Cat: now I shall have somebody to talk to.''How are you getting on?' said the Cat, " + "as soon as there was mouth enough for it to speak with.Alice waited till the eyes appeared, and then nodded. " + "'It's no use speaking to it,' she thought, 'till its ears have come, or at least one of them.' In another " + "minute the whole head appeared, and then Alice put down her flamingo, and began an account of the game, " + "feeling very glad she had someone to listen to her. The Cat seemed to think that there was enough of it now " + "in sight, and no more of it appeared.'I don't think they play at all fairly,' Alice began, in rather a " + "complaining tone, 'and they all quarrel so dreadfully one can't hear oneself speak—and they don't seem to " + "have any rules in particular; at least, if there are, nobody attends to them—and you've no idea how confusing " + "it is all the things being alive; for instance, there's the arch I've got to go through next walking about at " + "the other end of the ground—and I should have croqueted the Queen's hedgehog just now, only it ran away when " + "it saw mine coming!''How do you like the Queen?' said the Cat in a low voice.'Not at all,' said Alice: 'she's " + "so extremely—' Just then she noticed that the Queen was close behind her, listening: so she went on, '—likely " + "to win, that it's hardly worth while finishing the game.'The Queen smiled and passed on.'Who are you talking " + "to?' said the King, going up to Alice, and looking at the Cat's head with great curiosity.'It's a friend of " + "mine—a Cheshire Cat,' said Alice: 'allow me to introduce it.''I don't like the look of it at all,' said the " + "King: 'however, it may kiss my hand if it likes.''I'd rather not,' the Cat remarked.'Don't be impertinent,' " + "said the King, 'and don't look at me like that!' He got behind Alice as he spoke.'A cat may look at a king,' " + "said Alice. 'I've read that in some book, but I don't remember where.''Well, it must be removed,' said the " + "King very decidedly, and he called the Queen, who was passing at the moment, 'My dear! I wish you would have " + "this cat removed!'The Queen had only one way of settling all difficulties, great or small. 'Off with his " + "head!' she said, without even looking round.'I'll fetch the executioner myself,' said the King eagerly, and " + "he hurried off.Alice thought she might as well go back, and see how the game was going on, as she heard the " + "Queen's voice in the distance, screaming with passion. She had already heard her sentence three of the " + "players to be executed for having missed their turns, and she did not like the look of things at all, as the " + "game was in such confusion that she never knew whether it was her turn or not. So she went in search of her " + "hedgehog.The hedgehog was engaged in a fight with another hedgehog, which seemed to Alice an excellent " + "opportunity for croqueting one of them with the other: the only difficulty was, that her flamingo was gone " + "across to the other side of the garden, where Alice could see it trying in a helpless sort of way to fly up " + "into a tree.By the time she had caught the flamingo and brought it back, the fight was over, and both the " + "hedgehogs were out of sight: 'but it doesn't matter much,' thought Alice, 'as all the arches are gone from " + "this side of the ground.' So she tucked it away under her arm, that it might not escape again, and went back " + "for a little more conversation with her friend.When she got back to the Cheshire Cat, she was surprised to " + "find quite a large crowd collected round it: there was a dispute going on between the executioner, the King, " + "and the Queen, who were all talking at once, while all the rest were quite silent, and looked very " + "uncomfortable.The moment Alice appeared, she was appealed to by all three to settle the question, and they " + "repeated their arguments to her, though, as they all spoke at once, she found it very hard indeed to make out " + "exactly what they said.The executioner's argument was, that you couldn't cut off a head unless there was a " + "body to cut it off from: that he had never had to do such a thing before, and he wasn't going to begin at his " + "time of life.The King's argument was, that anything that had a head could be beheaded, and that you weren't " + "to talk nonsense.The Queen's argument was, that if something wasn't done about it in less than no time she'd " + "have everybody executed, all round. (It was this last remark that had made the whole party look so grave and " + "anxious.)Alice could think of nothing else to say but 'It belongs to the Duchess: you'd better ask her about " + "it.''She's in prison,' the Queen said to the executioner: 'fetch her here.' And the executioner went off like " + "an arrow.The Cat's head began fading away the moment he was gone, and, by the time he had come back with the " + "Duchess, it had entirely disappeared; so the King and the executioner ran wildly up and down looking for it, " + "while the rest of the party went back to the game."; + std::string output = + "QSBsYXJnZSByb3NlLXRyZWUgc3Rvb2QgbmVhciB0aGUgZW50cmFuY2Ugb2YgdGhlIGdhcmRlbjogdGhlIHJvc2VzIGdyb3dpbmcgb24gaXQgd2" + "VyZSB3aGl0ZSwgYnV0IHRoZXJlIHdlcmUgdGhyZWUgZ2FyZGVuZXJzIGF0IGl0LCBidXNpbHkgcGFpbnRpbmcgdGhlbSByZWQuIEFsaWNlIHRo" + "b3VnaHQgdGhpcyBhIHZlcnkgY3VyaW91cyB0aGluZywgYW5kIHNoZSB3ZW50IG5lYXJlciB0byB3YXRjaCB0aGVtLCBhbmQganVzdCBhcyBzaG" + "UgY2FtZSB1cCB0byB0aGVtIHNoZSBoZWFyZCBvbmUgb2YgdGhlbSBzYXksICdMb29rIG91dCBub3csIEZpdmUhIERvbid0IGdvIHNwbGFzaGlu" + "ZyBwYWludCBvdmVyIG1lIGxpa2UgdGhhdCEnJ0kgY291bGRuJ3QgaGVscCBpdCwnIHNhaWQgRml2ZSwgaW4gYSBzdWxreSB0b25lOyAnU2V2ZW" + "4gam9nZ2VkIG15IGVsYm93LidPbiB3aGljaCBTZXZlbiBsb29rZWQgdXAgYW5kIHNhaWQsICdUaGF0J3MgcmlnaHQsIEZpdmUhIEFsd2F5cyBs" + "YXkgdGhlIGJsYW1lIG9uIG90aGVycyEnJ1lvdSdkIGJldHRlciBub3QgdGFsayEnIHNhaWQgRml2ZS4gJ0kgaGVhcmQgdGhlIFF1ZWVuIHNheS" + "Bvbmx5IHllc3RlcmRheSB5b3UgZGVzZXJ2ZWQgdG8gYmUgYmVoZWFkZWQhJydXaGF0IGZvcj8nIHNhaWQgdGhlIG9uZSB3aG8gaGFkIHNwb2tl" + "biBmaXJzdC4nVGhhdCdzIG5vbmUgb2YgeW91ciBidXNpbmVzcywgVHdvIScgc2FpZCBTZXZlbi4nWWVzLCBpdCBpcyBoaXMgYnVzaW5lc3MhJy" + "BzYWlkIEZpdmUsICdhbmQgSSdsbCB0ZWxsIGhpbeKAlGl0IHdhcyBmb3IgYnJpbmdpbmcgdGhlIGNvb2sgdHVsaXAtcm9vdHMgaW5zdGVhZCBv" + "ZiBvbmlvbnMuJ1NldmVuIGZsdW5nIGRvd24gaGlzIGJydXNoLCBhbmQgaGFkIGp1c3QgYmVndW4gJ1dlbGwsIG9mIGFsbCB0aGUgdW5qdXN0IH" + "RoaW5nc+" + "KAlCcgd2hlbiBoaXMgZXllIGNoYW5jZWQgdG8gZmFsbCB1cG9uIEFsaWNlLCBhcyBzaGUgc3Rvb2Qgd2F0Y2hpbmcgdGhlbSwgYW5kIGhlIGNo" + "ZWNrZWQgaGltc2VsZiBzdWRkZW5seTogdGhlIG90aGVycyBsb29rZWQgcm91bmQgYWxzbywgYW5kIGFsbCBvZiB0aGVtIGJvd2VkIGxvdy4nV2" + "91bGQgeW91IHRlbGwgbWUsJyBzYWlkIEFsaWNlLCBhIGxpdHRsZSB0aW1pZGx5LCAnd2h5IHlvdSBhcmUgcGFpbnRpbmcgdGhvc2Ugcm9zZXM/" + "J0ZpdmUgYW5kIFNldmVuIHNhaWQgbm90aGluZywgYnV0IGxvb2tlZCBhdCBUd28uIFR3byBiZWdhbiBpbiBhIGxvdyB2b2ljZSwgJ1doeSB0aG" + "UgZmFjdCBpcywgeW91IHNlZSwgTWlzcywgdGhpcyBoZXJlIG91Z2h0IHRvIGhhdmUgYmVlbiBhIHJlZCByb3NlLXRyZWUsIGFuZCB3ZSBwdXQg" + "YSB3aGl0ZSBvbmUgaW4gYnkgbWlzdGFrZTsgYW5kIGlmIHRoZSBRdWVlbiB3YXMgdG8gZmluZCBpdCBvdXQsIHdlIHNob3VsZCBhbGwgaGF2ZS" + "BvdXIgaGVhZHMgY3V0IG9mZiwgeW91IGtub3cuIFNvIHlvdSBzZWUsIE1pc3MsIHdlJ3JlIGRvaW5nIG91ciBiZXN0LCBhZm9yZSBzaGUgY29t" + "ZXMsIHRv4oCUJyBBdCB0aGlzIG1vbWVudCBGaXZlLCB3aG8gaGFkIGJlZW4gYW54aW91c2x5IGxvb2tpbmcgYWNyb3NzIHRoZSBnYXJkZW4sIG" + "NhbGxlZCBvdXQgJ1RoZSBRdWVlbiEgVGhlIFF1ZWVuIScgYW5kIHRoZSB0aHJlZSBnYXJkZW5lcnMgaW5zdGFudGx5IHRocmV3IHRoZW1zZWx2" + "ZXMgZmxhdCB1cG9uIHRoZWlyIGZhY2VzLiBUaGVyZSB3YXMgYSBzb3VuZCBvZiBtYW55IGZvb3RzdGVwcywgYW5kIEFsaWNlIGxvb2tlZCByb3" + "VuZCwgZWFnZXIgdG8gc2VlIHRoZSBRdWVlbi5GaXJzdCBjYW1lIHRlbiBzb2xkaWVycyBjYXJyeWluZyBjbHViczsgdGhlc2Ugd2VyZSBhbGwg" + "c2hhcGVkIGxpa2UgdGhlIHRocmVlIGdhcmRlbmVycywgb2Jsb25nIGFuZCBmbGF0LCB3aXRoIHRoZWlyIGhhbmRzIGFuZCBmZWV0IGF0IHRoZS" + "Bjb3JuZXJzOiBuZXh0IHRoZSB0ZW4gY291cnRpZXJzOyB0aGVzZSB3ZXJlIG9ybmFtZW50ZWQgYWxsIG92ZXIgd2l0aCBkaWFtb25kcywgYW5k" + "IHdhbGtlZCB0d28gYW5kIHR3bywgYXMgdGhlIHNvbGRpZXJzIGRpZC4gQWZ0ZXIgdGhlc2UgY2FtZSB0aGUgcm95YWwgY2hpbGRyZW47IHRoZX" + "JlIHdlcmUgdGVuIG9mIHRoZW0sIGFuZCB0aGUgbGl0dGxlIGRlYXJzIGNhbWUganVtcGluZyBtZXJyaWx5IGFsb25nIGhhbmQgaW4gaGFuZCwg" + "aW4gY291cGxlczogdGhleSB3ZXJlIGFsbCBvcm5hbWVudGVkIHdpdGggaGVhcnRzLiBOZXh0IGNhbWUgdGhlIGd1ZXN0cywgbW9zdGx5IEtpbm" + "dzIGFuZCBRdWVlbnMsIGFuZCBhbW9uZyB0aGVtIEFsaWNlIHJlY29nbmlzZWQgdGhlIFdoaXRlIFJhYmJpdDogaXQgd2FzIHRhbGtpbmcgaW4g" + "YSBodXJyaWVkIG5lcnZvdXMgbWFubmVyLCBzbWlsaW5nIGF0IGV2ZXJ5dGhpbmcgdGhhdCB3YXMgc2FpZCwgYW5kIHdlbnQgYnkgd2l0aG91dC" + "Bub3RpY2luZyBoZXIuIFRoZW4gZm9sbG93ZWQgdGhlIEtuYXZlIG9mIEhlYXJ0cywgY2FycnlpbmcgdGhlIEtpbmcncyBjcm93biBvbiBhIGNy" + "aW1zb24gdmVsdmV0IGN1c2hpb247IGFuZCwgbGFzdCBvZiBhbGwgdGhpcyBncmFuZCBwcm9jZXNzaW9uLCBjYW1lIFRIRSBLSU5HIEFORCBRVU" + "VFTiBPRiBIRUFSVFMuQWxpY2Ugd2FzIHJhdGhlciBkb3VidGZ1bCB3aGV0aGVyIHNoZSBvdWdodCBub3QgdG8gbGllIGRvd24gb24gaGVyIGZh" + "Y2UgbGlrZSB0aGUgdGhyZWUgZ2FyZGVuZXJzLCBidXQgc2hlIGNvdWxkIG5vdCByZW1lbWJlciBldmVyIGhhdmluZyBoZWFyZCBvZiBzdWNoIG" + "EgcnVsZSBhdCBwcm9jZXNzaW9uczsgJ2FuZCBiZXNpZGVzLCB3aGF0IHdvdWxkIGJlIHRoZSB1c2Ugb2YgYSBwcm9jZXNzaW9uLCcgdGhvdWdo" + "dCBzaGUsICdpZiBwZW9wbGUgaGFkIGFsbCB0byBsaWUgZG93biB1cG9uIHRoZWlyIGZhY2VzLCBzbyB0aGF0IHRoZXkgY291bGRuJ3Qgc2VlIG" + "l0PycgU28gc2hlIHN0b29kIHN0aWxsIHdoZXJlIHNoZSB3YXMsIGFuZCB3YWl0ZWQuV2hlbiB0aGUgcHJvY2Vzc2lvbiBjYW1lIG9wcG9zaXRl" + "IHRvIEFsaWNlLCB0aGV5IGFsbCBzdG9wcGVkIGFuZCBsb29rZWQgYXQgaGVyLCBhbmQgdGhlIFF1ZWVuIHNhaWQgc2V2ZXJlbHkgJ1dobyBpcy" + "B0aGlzPycgU2hlIHNhaWQgaXQgdG8gdGhlIEtuYXZlIG9mIEhlYXJ0cywgd2hvIG9ubHkgYm93ZWQgYW5kIHNtaWxlZCBpbiByZXBseS4nSWRp" + "b3QhJyBzYWlkIHRoZSBRdWVlbiwgdG9zc2luZyBoZXIgaGVhZCBpbXBhdGllbnRseTsgYW5kLCB0dXJuaW5nIHRvIEFsaWNlLCBzaGUgd2VudC" + "BvbiwgJ1doYXQncyB5b3VyIG5hbWUsIGNoaWxkPycnTXkgbmFtZSBpcyBBbGljZSwgc28gcGxlYXNlIHlvdXIgTWFqZXN0eSwnIHNhaWQgQWxp" + "Y2UgdmVyeSBwb2xpdGVseTsgYnV0IHNoZSBhZGRlZCwgdG8gaGVyc2VsZiwgJ1doeSwgdGhleSdyZSBvbmx5IGEgcGFjayBvZiBjYXJkcywgYW" + "Z0ZXIgYWxsLiBJIG5lZWRuJ3QgYmUgYWZyYWlkIG9mIHRoZW0hJydBbmQgd2hvIGFyZSB0aGVzZT8nIHNhaWQgdGhlIFF1ZWVuLCBwb2ludGlu" + "ZyB0byB0aGUgdGhyZWUgZ2FyZGVuZXJzIHdobyB3ZXJlIGx5aW5nIHJvdW5kIHRoZSByb3NldHJlZTsgZm9yLCB5b3Ugc2VlLCBhcyB0aGV5IH" + "dlcmUgbHlpbmcgb24gdGhlaXIgZmFjZXMsIGFuZCB0aGUgcGF0dGVybiBvbiB0aGVpciBiYWNrcyB3YXMgdGhlIHNhbWUgYXMgdGhlIHJlc3Qg" + "b2YgdGhlIHBhY2ssIHNoZSBjb3VsZCBub3QgdGVsbCB3aGV0aGVyIHRoZXkgd2VyZSBnYXJkZW5lcnMsIG9yIHNvbGRpZXJzLCBvciBjb3VydG" + "llcnMsIG9yIHRocmVlIG9mIGhlciBvd24gY2hpbGRyZW4uJ0hvdyBzaG91bGQgSSBrbm93Pycgc2FpZCBBbGljZSwgc3VycHJpc2VkIGF0IGhl" + "ciBvd24gY291cmFnZS4gJ0l0J3Mgbm8gYnVzaW5lc3Mgb2YgbWluZS4nVGhlIFF1ZWVuIHR1cm5lZCBjcmltc29uIHdpdGggZnVyeSwgYW5kLC" + "BhZnRlciBnbGFyaW5nIGF0IGhlciBmb3IgYSBtb21lbnQgbGlrZSBhIHdpbGQgYmVhc3QsIHNjcmVhbWVkICdPZmYgd2l0aCBoZXIgaGVhZCEg" + "T2Zm4oCUJydOb25zZW5zZSEnIHNhaWQgQWxpY2UsIHZlcnkgbG91ZGx5IGFuZCBkZWNpZGVkbHksIGFuZCB0aGUgUXVlZW4gd2FzIHNpbGVudC" + "5UaGUgS2luZyBsYWlkIGhpcyBoYW5kIHVwb24gaGVyIGFybSwgYW5kIHRpbWlkbHkgc2FpZCAnQ29uc2lkZXIsIG15IGRlYXI6IHNoZSBpcyBv" + "bmx5IGEgY2hpbGQhJ1RoZSBRdWVlbiB0dXJuZWQgYW5ncmlseSBhd2F5IGZyb20gaGltLCBhbmQgc2FpZCB0byB0aGUgS25hdmUgJ1R1cm4gdG" + "hlbSBvdmVyISdUaGUgS25hdmUgZGlkIHNvLCB2ZXJ5IGNhcmVmdWxseSwgd2l0aCBvbmUgZm9vdC4nR2V0IHVwIScgc2FpZCB0aGUgUXVlZW4s" + "IGluIGEgc2hyaWxsLCBsb3VkIHZvaWNlLCBhbmQgdGhlIHRocmVlIGdhcmRlbmVycyBpbnN0YW50bHkganVtcGVkIHVwLCBhbmQgYmVnYW4gYm" + "93aW5nIHRvIHRoZSBLaW5nLCB0aGUgUXVlZW4sIHRoZSByb3lhbCBjaGlsZHJlbiwgYW5kIGV2ZXJ5Ym9keSBlbHNlLidMZWF2ZSBvZmYgdGhh" + "dCEnIHNjcmVhbWVkIHRoZSBRdWVlbi4gJ1lvdSBtYWtlIG1lIGdpZGR5LicgQW5kIHRoZW4sIHR1cm5pbmcgdG8gdGhlIHJvc2UtdHJlZSwgc2" + "hlIHdlbnQgb24sICdXaGF0IGhhdmUgeW91IGJlZW4gZG9pbmcgaGVyZT8nJ01heSBpdCBwbGVhc2UgeW91ciBNYWplc3R5LCcgc2FpZCBUd28s" + "IGluIGEgdmVyeSBodW1ibGUgdG9uZSwgZ29pbmcgZG93biBvbiBvbmUga25lZSBhcyBoZSBzcG9rZSwgJ3dlIHdlcmUgdHJ5aW5n4oCUJydJIH" + "NlZSEnIHNhaWQgdGhlIFF1ZWVuLCB3aG8gaGFkIG1lYW53aGlsZSBiZWVuIGV4YW1pbmluZyB0aGUgcm9zZXMuICdPZmYgd2l0aCB0aGVpciBo" + "ZWFkcyEnIGFuZCB0aGUgcHJvY2Vzc2lvbiBtb3ZlZCBvbiwgdGhyZWUgb2YgdGhlIHNvbGRpZXJzIHJlbWFpbmluZyBiZWhpbmQgdG8gZXhlY3" + "V0ZSB0aGUgdW5mb3J0dW5hdGUgZ2FyZGVuZXJzLCB3aG8gcmFuIHRvIEFsaWNlIGZvciBwcm90ZWN0aW9uLidZb3Ugc2hhbid0IGJlIGJlaGVh" + "ZGVkIScgc2FpZCBBbGljZSwgYW5kIHNoZSBwdXQgdGhlbSBpbnRvIGEgbGFyZ2UgZmxvd2VyLXBvdCB0aGF0IHN0b29kIG5lYXIuIFRoZSB0aH" + "JlZSBzb2xkaWVycyB3YW5kZXJlZCBhYm91dCBmb3IgYSBtaW51dGUgb3IgdHdvLCBsb29raW5nIGZvciB0aGVtLCBhbmQgdGhlbiBxdWlldGx5" + "IG1hcmNoZWQgb2ZmIGFmdGVyIHRoZSBvdGhlcnMuJ0FyZSB0aGVpciBoZWFkcyBvZmY/" + "JyBzaG91dGVkIHRoZSBRdWVlbi4nVGhlaXIgaGVhZHMgYXJlIGdvbmUsIGlmIGl0IHBsZWFzZSB5b3VyIE1hamVzdHkhJyB0aGUgc29sZGllcn" + "Mgc2hvdXRlZCBpbiByZXBseS4nVGhhdCdzIHJpZ2h0IScgc2hvdXRlZCB0aGUgUXVlZW4uICdDYW4geW91IHBsYXkgY3JvcXVldD8nVGhlIHNv" + "bGRpZXJzIHdlcmUgc2lsZW50LCBhbmQgbG9va2VkIGF0IEFsaWNlLCBhcyB0aGUgcXVlc3Rpb24gd2FzIGV2aWRlbnRseSBtZWFudCBmb3IgaG" + "VyLidZZXMhJyBzaG91dGVkIEFsaWNlLidDb21lIG9uLCB0aGVuIScgcm9hcmVkIHRoZSBRdWVlbiwgYW5kIEFsaWNlIGpvaW5lZCB0aGUgcHJv" + "Y2Vzc2lvbiwgd29uZGVyaW5nIHZlcnkgbXVjaCB3aGF0IHdvdWxkIGhhcHBlbiBuZXh0LidJdCdz4oCUaXQncyBhIHZlcnkgZmluZSBkYXkhJy" + "BzYWlkIGEgdGltaWQgdm9pY2UgYXQgaGVyIHNpZGUuIFNoZSB3YXMgd2Fsa2luZyBieSB0aGUgV2hpdGUgUmFiYml0LCB3aG8gd2FzIHBlZXBp" + "bmcgYW54aW91c2x5IGludG8gaGVyIGZhY2UuJ1ZlcnksJyBzYWlkIEFsaWNlOiAn4oCUd2hlcmUncyB0aGUgRHVjaGVzcz8nJ0h1c2ghIEh1c2" + "ghJyBzYWlkIHRoZSBSYWJiaXQgaW4gYSBsb3csIGh1cnJpZWQgdG9uZS4gSGUgbG9va2VkIGFueGlvdXNseSBvdmVyIGhpcyBzaG91bGRlciBh" + "cyBoZSBzcG9rZSwgYW5kIHRoZW4gcmFpc2VkIGhpbXNlbGYgdXBvbiB0aXB0b2UsIHB1dCBoaXMgbW91dGggY2xvc2UgdG8gaGVyIGVhciwgYW" + "5kIHdoaXNwZXJlZCAnU2hlJ3MgdW5kZXIgc2VudGVuY2Ugb2YgZXhlY3V0aW9uLicnV2hhdCBmb3I/" + "JyBzYWlkIEFsaWNlLidEaWQgeW91IHNheSAiV2hhdCBhIHBpdHkhIj8nIHRoZSBSYWJiaXQgYXNrZWQuJ05vLCBJIGRpZG4ndCwnIHNhaWQgQW" + "xpY2U6ICdJIGRvbid0IHRoaW5rIGl0J3MgYXQgYWxsIGEgcGl0eS4gSSBzYWlkICJXaGF0IGZvcj8iJydTaGUgYm94ZWQgdGhlIFF1ZWVuJ3Mg" + "ZWFyc+" + "KAlCcgdGhlIFJhYmJpdCBiZWdhbi4gQWxpY2UgZ2F2ZSBhIGxpdHRsZSBzY3JlYW0gb2YgbGF1Z2h0ZXIuICdPaCwgaHVzaCEnIHRoZSBSYWJi" + "aXQgd2hpc3BlcmVkIGluIGEgZnJpZ2h0ZW5lZCB0b25lLiAnVGhlIFF1ZWVuIHdpbGwgaGVhciB5b3UhIFlvdSBzZWUsIHNoZSBjYW1lIHJhdG" + "hlciBsYXRlLCBhbmQgdGhlIFF1ZWVuIHNhaWTigJQnJ0dldCB0byB5b3VyIHBsYWNlcyEnIHNob3V0ZWQgdGhlIFF1ZWVuIGluIGEgdm9pY2Ug" + "b2YgdGh1bmRlciwgYW5kIHBlb3BsZSBiZWdhbiBydW5uaW5nIGFib3V0IGluIGFsbCBkaXJlY3Rpb25zLCB0dW1ibGluZyB1cCBhZ2FpbnN0IG" + "VhY2ggb3RoZXI7IGhvd2V2ZXIsIHRoZXkgZ290IHNldHRsZWQgZG93biBpbiBhIG1pbnV0ZSBvciB0d28sIGFuZCB0aGUgZ2FtZSBiZWdhbi4g" + "QWxpY2UgdGhvdWdodCBzaGUgaGFkIG5ldmVyIHNlZW4gc3VjaCBhIGN1cmlvdXMgY3JvcXVldC1ncm91bmQgaW4gaGVyIGxpZmU7IGl0IHdhcy" + "BhbGwgcmlkZ2VzIGFuZCBmdXJyb3dzOyB0aGUgYmFsbHMgd2VyZSBsaXZlIGhlZGdlaG9ncywgdGhlIG1hbGxldHMgbGl2ZSBmbGFtaW5nb2Vz" + "LCBhbmQgdGhlIHNvbGRpZXJzIGhhZCB0byBkb3VibGUgdGhlbXNlbHZlcyB1cCBhbmQgdG8gc3RhbmQgb24gdGhlaXIgaGFuZHMgYW5kIGZlZX" + "QsIHRvIG1ha2UgdGhlIGFyY2hlcy5UaGUgY2hpZWYgZGlmZmljdWx0eSBBbGljZSBmb3VuZCBhdCBmaXJzdCB3YXMgaW4gbWFuYWdpbmcgaGVy" + "IGZsYW1pbmdvOiBzaGUgc3VjY2VlZGVkIGluIGdldHRpbmcgaXRzIGJvZHkgdHVja2VkIGF3YXksIGNvbWZvcnRhYmx5IGVub3VnaCwgdW5kZX" + "IgaGVyIGFybSwgd2l0aCBpdHMgbGVncyBoYW5naW5nIGRvd24sIGJ1dCBnZW5lcmFsbHksIGp1c3QgYXMgc2hlIGhhZCBnb3QgaXRzIG5lY2sg" + "bmljZWx5IHN0cmFpZ2h0ZW5lZCBvdXQsIGFuZCB3YXMgZ29pbmcgdG8gZ2l2ZSB0aGUgaGVkZ2Vob2cgYSBibG93IHdpdGggaXRzIGhlYWQsIG" + "l0IHdvdWxkIHR3aXN0IGl0c2VsZiByb3VuZCBhbmQgbG9vayB1cCBpbiBoZXIgZmFjZSwgd2l0aCBzdWNoIGEgcHV6emxlZCBleHByZXNzaW9u" + "IHRoYXQgc2hlIGNvdWxkIG5vdCBoZWxwIGJ1cnN0aW5nIG91dCBsYXVnaGluZzogYW5kIHdoZW4gc2hlIGhhZCBnb3QgaXRzIGhlYWQgZG93bi" + "wgYW5kIHdhcyBnb2luZyB0byBiZWdpbiBhZ2FpbiwgaXQgd2FzIHZlcnkgcHJvdm9raW5nIHRvIGZpbmQgdGhhdCB0aGUgaGVkZ2Vob2cgaGFk" + "IHVucm9sbGVkIGl0c2VsZiwgYW5kIHdhcyBpbiB0aGUgYWN0IG9mIGNyYXdsaW5nIGF3YXk6IGJlc2lkZXMgYWxsIHRoaXMsIHRoZXJlIHdhcy" + "BnZW5lcmFsbHkgYSByaWRnZSBvciBmdXJyb3cgaW4gdGhlIHdheSB3aGVyZXZlciBzaGUgd2FudGVkIHRvIHNlbmQgdGhlIGhlZGdlaG9nIHRv" + "LCBhbmQsIGFzIHRoZSBkb3VibGVkLXVwIHNvbGRpZXJzIHdlcmUgYWx3YXlzIGdldHRpbmcgdXAgYW5kIHdhbGtpbmcgb2ZmIHRvIG90aGVyIH" + "BhcnRzIG9mIHRoZSBncm91bmQsIEFsaWNlIHNvb24gY2FtZSB0byB0aGUgY29uY2x1c2lvbiB0aGF0IGl0IHdhcyBhIHZlcnkgZGlmZmljdWx0" + "IGdhbWUgaW5kZWVkLlRoZSBwbGF5ZXJzIGFsbCBwbGF5ZWQgYXQgb25jZSB3aXRob3V0IHdhaXRpbmcgZm9yIHR1cm5zLCBxdWFycmVsbGluZy" + "BhbGwgdGhlIHdoaWxlLCBhbmQgZmlnaHRpbmcgZm9yIHRoZSBoZWRnZWhvZ3M7IGFuZCBpbiBhIHZlcnkgc2hvcnQgdGltZSB0aGUgUXVlZW4g" + "d2FzIGluIGEgZnVyaW91cyBwYXNzaW9uLCBhbmQgd2VudCBzdGFtcGluZyBhYm91dCwgYW5kIHNob3V0aW5nICdPZmYgd2l0aCBoaXMgaGVhZC" + "EnIG9yICdPZmYgd2l0aCBoZXIgaGVhZCEnIGFib3V0IG9uY2UgaW4gYSBtaW51dGUuQWxpY2UgYmVnYW4gdG8gZmVlbCB2ZXJ5IHVuZWFzeTog" + "dG8gYmUgc3VyZSwgc2hlIGhhZCBub3QgYXMgeWV0IGhhZCBhbnkgZGlzcHV0ZSB3aXRoIHRoZSBRdWVlbiwgYnV0IHNoZSBrbmV3IHRoYXQgaX" + "QgbWlnaHQgaGFwcGVuIGFueSBtaW51dGUsICdhbmQgdGhlbiwnIHRob3VnaHQgc2hlLCAnd2hhdCB3b3VsZCBiZWNvbWUgb2YgbWU/" + "IFRoZXkncmUgZHJlYWRmdWxseSBmb25kIG9mIGJlaGVhZGluZyBwZW9wbGUgaGVyZTsgdGhlIGdyZWF0IHdvbmRlciBpcywgdGhhdCB0aGVyZS" + "dzIGFueSBvbmUgbGVmdCBhbGl2ZSEnU2hlIHdhcyBsb29raW5nIGFib3V0IGZvciBzb21lIHdheSBvZiBlc2NhcGUsIGFuZCB3b25kZXJpbmcg" + "d2hldGhlciBzaGUgY291bGQgZ2V0IGF3YXkgd2l0aG91dCBiZWluZyBzZWVuLCB3aGVuIHNoZSBub3RpY2VkIGEgY3VyaW91cyBhcHBlYXJhbm" + "NlIGluIHRoZSBhaXI6IGl0IHB1enpsZWQgaGVyIHZlcnkgbXVjaCBhdCBmaXJzdCwgYnV0LCBhZnRlciB3YXRjaGluZyBpdCBhIG1pbnV0ZSBv" + "ciB0d28sIHNoZSBtYWRlIGl0IG91dCB0byBiZSBhIGdyaW4sIGFuZCBzaGUgc2FpZCB0byBoZXJzZWxmICdJdCdzIHRoZSBDaGVzaGlyZSBDYX" + "Q6IG5vdyBJIHNoYWxsIGhhdmUgc29tZWJvZHkgdG8gdGFsayB0by4nJ0hvdyBhcmUgeW91IGdldHRpbmcgb24/" + "JyBzYWlkIHRoZSBDYXQsIGFzIHNvb24gYXMgdGhlcmUgd2FzIG1vdXRoIGVub3VnaCBmb3IgaXQgdG8gc3BlYWsgd2l0aC5BbGljZSB3YWl0ZW" + "QgdGlsbCB0aGUgZXllcyBhcHBlYXJlZCwgYW5kIHRoZW4gbm9kZGVkLiAnSXQncyBubyB1c2Ugc3BlYWtpbmcgdG8gaXQsJyBzaGUgdGhvdWdo" + "dCwgJ3RpbGwgaXRzIGVhcnMgaGF2ZSBjb21lLCBvciBhdCBsZWFzdCBvbmUgb2YgdGhlbS4nIEluIGFub3RoZXIgbWludXRlIHRoZSB3aG9sZS" + "BoZWFkIGFwcGVhcmVkLCBhbmQgdGhlbiBBbGljZSBwdXQgZG93biBoZXIgZmxhbWluZ28sIGFuZCBiZWdhbiBhbiBhY2NvdW50IG9mIHRoZSBn" + "YW1lLCBmZWVsaW5nIHZlcnkgZ2xhZCBzaGUgaGFkIHNvbWVvbmUgdG8gbGlzdGVuIHRvIGhlci4gVGhlIENhdCBzZWVtZWQgdG8gdGhpbmsgdG" + "hhdCB0aGVyZSB3YXMgZW5vdWdoIG9mIGl0IG5vdyBpbiBzaWdodCwgYW5kIG5vIG1vcmUgb2YgaXQgYXBwZWFyZWQuJ0kgZG9uJ3QgdGhpbmsg" + "dGhleSBwbGF5IGF0IGFsbCBmYWlybHksJyBBbGljZSBiZWdhbiwgaW4gcmF0aGVyIGEgY29tcGxhaW5pbmcgdG9uZSwgJ2FuZCB0aGV5IGFsbC" + "BxdWFycmVsIHNvIGRyZWFkZnVsbHkgb25lIGNhbid0IGhlYXIgb25lc2VsZiBzcGVha+" + "KAlGFuZCB0aGV5IGRvbid0IHNlZW0gdG8gaGF2ZSBhbnkgcnVsZXMgaW4gcGFydGljdWxhcjsgYXQgbGVhc3QsIGlmIHRoZXJlIGFyZSwgbm9i" + "b2R5IGF0dGVuZHMgdG8gdGhlbeKAlGFuZCB5b3UndmUgbm8gaWRlYSBob3cgY29uZnVzaW5nIGl0IGlzIGFsbCB0aGUgdGhpbmdzIGJlaW5nIG" + "FsaXZlOyBmb3IgaW5zdGFuY2UsIHRoZXJlJ3MgdGhlIGFyY2ggSSd2ZSBnb3QgdG8gZ28gdGhyb3VnaCBuZXh0IHdhbGtpbmcgYWJvdXQgYXQg" + "dGhlIG90aGVyIGVuZCBvZiB0aGUgZ3JvdW5k4oCUYW5kIEkgc2hvdWxkIGhhdmUgY3JvcXVldGVkIHRoZSBRdWVlbidzIGhlZGdlaG9nIGp1c3" + "Qgbm93LCBvbmx5IGl0IHJhbiBhd2F5IHdoZW4gaXQgc2F3IG1pbmUgY29taW5nIScnSG93IGRvIHlvdSBsaWtlIHRoZSBRdWVlbj8nIHNhaWQg" + "dGhlIENhdCBpbiBhIGxvdyB2b2ljZS4nTm90IGF0IGFsbCwnIHNhaWQgQWxpY2U6ICdzaGUncyBzbyBleHRyZW1lbHnigJQnIEp1c3QgdGhlbi" + "BzaGUgbm90aWNlZCB0aGF0IHRoZSBRdWVlbiB3YXMgY2xvc2UgYmVoaW5kIGhlciwgbGlzdGVuaW5nOiBzbyBzaGUgd2VudCBvbiwgJ+" + "KAlGxpa2VseSB0byB3aW4sIHRoYXQgaXQncyBoYXJkbHkgd29ydGggd2hpbGUgZmluaXNoaW5nIHRoZSBnYW1lLidUaGUgUXVlZW4gc21pbGVk" + "IGFuZCBwYXNzZWQgb24uJ1dobyBhcmUgeW91IHRhbGtpbmcgdG8/" + "JyBzYWlkIHRoZSBLaW5nLCBnb2luZyB1cCB0byBBbGljZSwgYW5kIGxvb2tpbmcgYXQgdGhlIENhdCdzIGhlYWQgd2l0aCBncmVhdCBjdXJpb3" + "NpdHkuJ0l0J3MgYSBmcmllbmQgb2YgbWluZeKAlGEgQ2hlc2hpcmUgQ2F0LCcgc2FpZCBBbGljZTogJ2FsbG93IG1lIHRvIGludHJvZHVjZSBp" + "dC4nJ0kgZG9uJ3QgbGlrZSB0aGUgbG9vayBvZiBpdCBhdCBhbGwsJyBzYWlkIHRoZSBLaW5nOiAnaG93ZXZlciwgaXQgbWF5IGtpc3MgbXkgaG" + "FuZCBpZiBpdCBsaWtlcy4nJ0knZCByYXRoZXIgbm90LCcgdGhlIENhdCByZW1hcmtlZC4nRG9uJ3QgYmUgaW1wZXJ0aW5lbnQsJyBzYWlkIHRo" + "ZSBLaW5nLCAnYW5kIGRvbid0IGxvb2sgYXQgbWUgbGlrZSB0aGF0IScgSGUgZ290IGJlaGluZCBBbGljZSBhcyBoZSBzcG9rZS4nQSBjYXQgbW" + "F5IGxvb2sgYXQgYSBraW5nLCcgc2FpZCBBbGljZS4gJ0kndmUgcmVhZCB0aGF0IGluIHNvbWUgYm9vaywgYnV0IEkgZG9uJ3QgcmVtZW1iZXIg" + "d2hlcmUuJydXZWxsLCBpdCBtdXN0IGJlIHJlbW92ZWQsJyBzYWlkIHRoZSBLaW5nIHZlcnkgZGVjaWRlZGx5LCBhbmQgaGUgY2FsbGVkIHRoZS" + "BRdWVlbiwgd2hvIHdhcyBwYXNzaW5nIGF0IHRoZSBtb21lbnQsICdNeSBkZWFyISBJIHdpc2ggeW91IHdvdWxkIGhhdmUgdGhpcyBjYXQgcmVt" + "b3ZlZCEnVGhlIFF1ZWVuIGhhZCBvbmx5IG9uZSB3YXkgb2Ygc2V0dGxpbmcgYWxsIGRpZmZpY3VsdGllcywgZ3JlYXQgb3Igc21hbGwuICdPZm" + "Ygd2l0aCBoaXMgaGVhZCEnIHNoZSBzYWlkLCB3aXRob3V0IGV2ZW4gbG9va2luZyByb3VuZC4nSSdsbCBmZXRjaCB0aGUgZXhlY3V0aW9uZXIg" + "bXlzZWxmLCcgc2FpZCB0aGUgS2luZyBlYWdlcmx5LCBhbmQgaGUgaHVycmllZCBvZmYuQWxpY2UgdGhvdWdodCBzaGUgbWlnaHQgYXMgd2VsbC" + "BnbyBiYWNrLCBhbmQgc2VlIGhvdyB0aGUgZ2FtZSB3YXMgZ29pbmcgb24sIGFzIHNoZSBoZWFyZCB0aGUgUXVlZW4ncyB2b2ljZSBpbiB0aGUg" + "ZGlzdGFuY2UsIHNjcmVhbWluZyB3aXRoIHBhc3Npb24uIFNoZSBoYWQgYWxyZWFkeSBoZWFyZCBoZXIgc2VudGVuY2UgdGhyZWUgb2YgdGhlIH" + "BsYXllcnMgdG8gYmUgZXhlY3V0ZWQgZm9yIGhhdmluZyBtaXNzZWQgdGhlaXIgdHVybnMsIGFuZCBzaGUgZGlkIG5vdCBsaWtlIHRoZSBsb29r" + "IG9mIHRoaW5ncyBhdCBhbGwsIGFzIHRoZSBnYW1lIHdhcyBpbiBzdWNoIGNvbmZ1c2lvbiB0aGF0IHNoZSBuZXZlciBrbmV3IHdoZXRoZXIgaX" + "Qgd2FzIGhlciB0dXJuIG9yIG5vdC4gU28gc2hlIHdlbnQgaW4gc2VhcmNoIG9mIGhlciBoZWRnZWhvZy5UaGUgaGVkZ2Vob2cgd2FzIGVuZ2Fn" + "ZWQgaW4gYSBmaWdodCB3aXRoIGFub3RoZXIgaGVkZ2Vob2csIHdoaWNoIHNlZW1lZCB0byBBbGljZSBhbiBleGNlbGxlbnQgb3Bwb3J0dW5pdH" + "kgZm9yIGNyb3F1ZXRpbmcgb25lIG9mIHRoZW0gd2l0aCB0aGUgb3RoZXI6IHRoZSBvbmx5IGRpZmZpY3VsdHkgd2FzLCB0aGF0IGhlciBmbGFt" + "aW5nbyB3YXMgZ29uZSBhY3Jvc3MgdG8gdGhlIG90aGVyIHNpZGUgb2YgdGhlIGdhcmRlbiwgd2hlcmUgQWxpY2UgY291bGQgc2VlIGl0IHRyeW" + "luZyBpbiBhIGhlbHBsZXNzIHNvcnQgb2Ygd2F5IHRvIGZseSB1cCBpbnRvIGEgdHJlZS5CeSB0aGUgdGltZSBzaGUgaGFkIGNhdWdodCB0aGUg" + "ZmxhbWluZ28gYW5kIGJyb3VnaHQgaXQgYmFjaywgdGhlIGZpZ2h0IHdhcyBvdmVyLCBhbmQgYm90aCB0aGUgaGVkZ2Vob2dzIHdlcmUgb3V0IG" + "9mIHNpZ2h0OiAnYnV0IGl0IGRvZXNuJ3QgbWF0dGVyIG11Y2gsJyB0aG91Z2h0IEFsaWNlLCAnYXMgYWxsIHRoZSBhcmNoZXMgYXJlIGdvbmUg" + "ZnJvbSB0aGlzIHNpZGUgb2YgdGhlIGdyb3VuZC4nIFNvIHNoZSB0dWNrZWQgaXQgYXdheSB1bmRlciBoZXIgYXJtLCB0aGF0IGl0IG1pZ2h0IG" + "5vdCBlc2NhcGUgYWdhaW4sIGFuZCB3ZW50IGJhY2sgZm9yIGEgbGl0dGxlIG1vcmUgY29udmVyc2F0aW9uIHdpdGggaGVyIGZyaWVuZC5XaGVu" + "IHNoZSBnb3QgYmFjayB0byB0aGUgQ2hlc2hpcmUgQ2F0LCBzaGUgd2FzIHN1cnByaXNlZCB0byBmaW5kIHF1aXRlIGEgbGFyZ2UgY3Jvd2QgY2" + "9sbGVjdGVkIHJvdW5kIGl0OiB0aGVyZSB3YXMgYSBkaXNwdXRlIGdvaW5nIG9uIGJldHdlZW4gdGhlIGV4ZWN1dGlvbmVyLCB0aGUgS2luZywg" + "YW5kIHRoZSBRdWVlbiwgd2hvIHdlcmUgYWxsIHRhbGtpbmcgYXQgb25jZSwgd2hpbGUgYWxsIHRoZSByZXN0IHdlcmUgcXVpdGUgc2lsZW50LC" + "BhbmQgbG9va2VkIHZlcnkgdW5jb21mb3J0YWJsZS5UaGUgbW9tZW50IEFsaWNlIGFwcGVhcmVkLCBzaGUgd2FzIGFwcGVhbGVkIHRvIGJ5IGFs" + "bCB0aHJlZSB0byBzZXR0bGUgdGhlIHF1ZXN0aW9uLCBhbmQgdGhleSByZXBlYXRlZCB0aGVpciBhcmd1bWVudHMgdG8gaGVyLCB0aG91Z2gsIG" + "FzIHRoZXkgYWxsIHNwb2tlIGF0IG9uY2UsIHNoZSBmb3VuZCBpdCB2ZXJ5IGhhcmQgaW5kZWVkIHRvIG1ha2Ugb3V0IGV4YWN0bHkgd2hhdCB0" + "aGV5IHNhaWQuVGhlIGV4ZWN1dGlvbmVyJ3MgYXJndW1lbnQgd2FzLCB0aGF0IHlvdSBjb3VsZG4ndCBjdXQgb2ZmIGEgaGVhZCB1bmxlc3MgdG" + "hlcmUgd2FzIGEgYm9keSB0byBjdXQgaXQgb2ZmIGZyb206IHRoYXQgaGUgaGFkIG5ldmVyIGhhZCB0byBkbyBzdWNoIGEgdGhpbmcgYmVmb3Jl" + "LCBhbmQgaGUgd2Fzbid0IGdvaW5nIHRvIGJlZ2luIGF0IGhpcyB0aW1lIG9mIGxpZmUuVGhlIEtpbmcncyBhcmd1bWVudCB3YXMsIHRoYXQgYW" + "55dGhpbmcgdGhhdCBoYWQgYSBoZWFkIGNvdWxkIGJlIGJlaGVhZGVkLCBhbmQgdGhhdCB5b3Ugd2VyZW4ndCB0byB0YWxrIG5vbnNlbnNlLlRo" + "ZSBRdWVlbidzIGFyZ3VtZW50IHdhcywgdGhhdCBpZiBzb21ldGhpbmcgd2Fzbid0IGRvbmUgYWJvdXQgaXQgaW4gbGVzcyB0aGFuIG5vIHRpbW" + "Ugc2hlJ2QgaGF2ZSBldmVyeWJvZHkgZXhlY3V0ZWQsIGFsbCByb3VuZC4gKEl0IHdhcyB0aGlzIGxhc3QgcmVtYXJrIHRoYXQgaGFkIG1hZGUg" + "dGhlIHdob2xlIHBhcnR5IGxvb2sgc28gZ3JhdmUgYW5kIGFueGlvdXMuKUFsaWNlIGNvdWxkIHRoaW5rIG9mIG5vdGhpbmcgZWxzZSB0byBzYX" + "kgYnV0ICdJdCBiZWxvbmdzIHRvIHRoZSBEdWNoZXNzOiB5b3UnZCBiZXR0ZXIgYXNrIGhlciBhYm91dCBpdC4nJ1NoZSdzIGluIHByaXNvbiwn" + "IHRoZSBRdWVlbiBzYWlkIHRvIHRoZSBleGVjdXRpb25lcjogJ2ZldGNoIGhlciBoZXJlLicgQW5kIHRoZSBleGVjdXRpb25lciB3ZW50IG9mZi" + "BsaWtlIGFuIGFycm93LlRoZSBDYXQncyBoZWFkIGJlZ2FuIGZhZGluZyBhd2F5IHRoZSBtb21lbnQgaGUgd2FzIGdvbmUsIGFuZCwgYnkgdGhl" + "IHRpbWUgaGUgaGFkIGNvbWUgYmFjayB3aXRoIHRoZSBEdWNoZXNzLCBpdCBoYWQgZW50aXJlbHkgZGlzYXBwZWFyZWQ7IHNvIHRoZSBLaW5nIG" + "FuZCB0aGUgZXhlY3V0aW9uZXIgcmFuIHdpbGRseSB1cCBhbmQgZG93biBsb29raW5nIGZvciBpdCwgd2hpbGUgdGhlIHJlc3Qgb2YgdGhlIHBh" + "cnR5IHdlbnQgYmFjayB0byB0aGUgZ2FtZS4="; + using it_base64_t = bai::base64_from_binary<bai::transform_width<std::string::const_iterator, 6, 8>>; + + auto writePaddChars = (3 - input.length() % 3) % 3; + std::string base64(it_base64_t(input.begin()), it_base64_t(input.end())); + base64.append(writePaddChars, '='); + assert(base64 == output); + return 0; +} +#elif 0 + +#include <memory> +#include <sstream> + +#include <boost/archive/text_iarchive.hpp> +#include <boost/archive/text_oarchive.hpp> +#include <boost/serialization/shared_ptr.hpp> + +struct S +{ + int i; + char c; + + template <class Archive> + void serialize(Archive & ar, const unsigned int version) + { + ar & i; + ar & c; + } +}; + +int main() +{ + const auto s0 = std::make_shared<S>(); + s0->i = 42; + s0->c = 'c'; + + std::stringstream ss; + + { + boost::archive::text_oarchive oa(ss); + oa << s0; + } + + std::shared_ptr<S> s1; + { + boost::archive::text_iarchive ia(ss); + ia >> s1; + } + + return 0; +} + +#elif 0 +#include <boost/archive/binary_iarchive.hpp> +#include <boost/serialization/vector.hpp> +#include <sstream> +#include <vector> + +void f() +{ + std::stringstream iss; + boost::archive::binary_iarchive ar(iss); + std::vector<int> out; + ar >> out; +} + +int main(int argc, char* argv[]) +{ + return 0; +} + +#include <boost/archive/xml_oarchive.hpp> +#include <boost/archive/xml_iarchive.hpp> +#include <boost/archive/detail/archive_serializer_map.hpp> +#include <boost/archive/impl/archive_serializer_map.ipp> +#include <boost/archive/impl/basic_xml_iarchive.ipp> +#include <boost/archive/impl/xml_iarchive_impl.ipp> +#include <boost/serialization/nvp.hpp> +#include <limits> +#include <fstream> + +class xml_iarchive_nan : +public boost::archive::xml_iarchive_impl<xml_iarchive_nan> +{ +protected: + friend class boost::archive::detail::interface_iarchive<xml_iarchive_nan>; + friend class boost::archive::detail::common_iarchive<xml_iarchive_nan>; + friend class boost::archive::basic_xml_iarchive<xml_iarchive_nan>; + friend class boost::archive::load_access; + + using boost::archive::xml_iarchive_impl<xml_iarchive_nan>::load; + void load(double & t) + { + char c='0'; + if(!is.fail()) + { + c=is.peek(); + if(c!='n') + { + boost::archive::xml_iarchive_impl<xml_iarchive_nan>::load(t); + } + else + { + char c1='0',c2='0'; + is.get(c).get(c1).get(c2); + if(is.fail()||(!((c=='n')&&(c1=='a')&&(c2=='n')))) + boost::serialization::throw_exception( + boost::archive::archive_exception( + boost::archive::archive_exception::input_stream_error)); + else + t=std::numeric_limits<double>::quiet_NaN(); + } + } + else + boost::serialization::throw_exception( + boost::archive::archive_exception(boost::archive::archive_exception::input_stream_error)); + } + +public: + xml_iarchive_nan(std::istream & is, unsigned int flags = 0) : + boost::archive::xml_iarchive_impl<xml_iarchive_nan>(is, flags) + {} + ~xml_iarchive_nan(){}; +}; + +BOOST_SERIALIZATION_REGISTER_ARCHIVE(xml_iarchive_nan) + +namespace boost +{ + namespace archive + { + template class detail::archive_serializer_map<xml_iarchive_nan>; + template class detail::interface_iarchive<xml_iarchive_nan>; + template class detail::common_iarchive<xml_iarchive_nan>; + template class basic_xml_iarchive<xml_iarchive_nan>; + template class xml_iarchive_impl<xml_iarchive_nan>; + + } +} + +int main(int argc, char** argv) +{ + double value=0.0; + std::ifstream ifile("./somefile.xml"); + xml_iarchive_nan ia(ifile); + ia>>BOOST_SERIALIZATION_NVP(value); +} + +#endif + +int main(int argc, char* argv[]) +{ + return 0; +} + diff --git a/src/boost/libs/serialization/test/testfile2 b/src/boost/libs/serialization/test/testfile2 Binary files differnew file mode 100644 index 00000000..c3fab950 --- /dev/null +++ b/src/boost/libs/serialization/test/testfile2 diff --git a/src/boost/libs/serialization/test/text_archive.hpp b/src/boost/libs/serialization/test/text_archive.hpp new file mode 100644 index 00000000..65425ce5 --- /dev/null +++ b/src/boost/libs/serialization/test/text_archive.hpp @@ -0,0 +1,13 @@ +// (C) Copyright 2002-4 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. +// text_archive +#include <boost/archive/text_oarchive.hpp> +typedef boost::archive::text_oarchive test_oarchive; +typedef std::ofstream test_ostream; +#include <boost/archive/text_iarchive.hpp> +typedef boost::archive::text_iarchive test_iarchive; +typedef std::ifstream test_istream; diff --git a/src/boost/libs/serialization/test/text_warchive.hpp b/src/boost/libs/serialization/test/text_warchive.hpp new file mode 100644 index 00000000..8f77bf2d --- /dev/null +++ b/src/boost/libs/serialization/test/text_warchive.hpp @@ -0,0 +1,13 @@ +// (C) Copyright 2002-4 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. +// text_warchive +#include <boost/archive/text_woarchive.hpp> +typedef boost::archive::text_woarchive test_oarchive; +typedef std::wofstream test_ostream; +#include <boost/archive/text_wiarchive.hpp> +typedef boost::archive::text_wiarchive test_iarchive; +typedef std::wifstream test_istream; diff --git a/src/boost/libs/serialization/test/xml_archive.hpp b/src/boost/libs/serialization/test/xml_archive.hpp new file mode 100644 index 00000000..c7ca3433 --- /dev/null +++ b/src/boost/libs/serialization/test/xml_archive.hpp @@ -0,0 +1,13 @@ +// (C) Copyright 2002-4 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. +// xml_archive +#include <boost/archive/xml_oarchive.hpp> +typedef boost::archive::xml_oarchive test_oarchive; +typedef std::ofstream test_ostream; +#include <boost/archive/xml_iarchive.hpp> +typedef boost::archive::xml_iarchive test_iarchive; +typedef std::ifstream test_istream; diff --git a/src/boost/libs/serialization/test/xml_warchive.hpp b/src/boost/libs/serialization/test/xml_warchive.hpp new file mode 100644 index 00000000..22e4dba6 --- /dev/null +++ b/src/boost/libs/serialization/test/xml_warchive.hpp @@ -0,0 +1,13 @@ +// (C) Copyright 2002-4 Robert Ramey - http://www.rrsd.com . +// Use, modification and distribution is subject to the Boost Software +// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org for updates, documentation, and revision history. +// xml_warchive +#include <boost/archive/xml_woarchive.hpp> +typedef boost::archive::xml_woarchive test_oarchive; +typedef std::wofstream test_ostream; +#include <boost/archive/xml_wiarchive.hpp> +typedef boost::archive::xml_wiarchive test_iarchive; +typedef std::wifstream test_istream; diff --git a/src/boost/libs/serialization/util/test.jam b/src/boost/libs/serialization/util/test.jam new file mode 100644 index 00000000..4a04c333 --- /dev/null +++ b/src/boost/libs/serialization/util/test.jam @@ -0,0 +1,208 @@ +# Boost serialization Library utility test Jamfile + +# (C) Copyright Robert Ramey 2002-2004. +# Use, modification, and distribution are subject to the +# Boost Software License, Version 1.0. (See accompanying file +# LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) +# + +# the file contains Jam rules which are used in both the normal +# boost test, as well as the performance test and comprehensive +# tests. + +# import rules for testing conditional on config file variables +import ../../config/checks/config : requires ; + +BOOST_ARCHIVE_LIST = [ modules.peek : BOOST_ARCHIVE_LIST ] ; + +# these are used to shorten testing while in development. It permits +# testing to be applied to just a particular type of archive +if ! $(BOOST_ARCHIVE_LIST) { + BOOST_ARCHIVE_LIST = + "text_archive.hpp" + "text_warchive.hpp" + "binary_archive.hpp" + "xml_archive.hpp" + "xml_warchive.hpp" + ; + # enable the tests which don't depend on a particular archive + BOOST_SERIALIZATION_TEST = true ; +} + +rule run-template ( test-name : sources * : files * : requirements * ) { + return [ + run + $(sources) + : # command + : #input files + $(files) + : # requirements + # toolset warnings + <toolset>borland:<cxxflags>"-w-8080 -w-8071 -w-8057 -w-8062 -w-8008 -w-0018 -w-8066" + #<toolset>gcc:<warnings>all # ? + <toolset>gcc:<cxxflags>"-Wno-unused-variable -Wno-long-long" + # <toolset>gcc:<variant>debug><define>_STLP_DEBUG + # <toolset>gcc:<variant>debug><define>_GLIBCXX_DEBUG + <toolset>darwin:<cxxflags>"-Wno-unused-variable -Wno-long-long" + <toolset>msvc:<warnings>all # == /W4 + <toolset>msvc:<define>_SCL_SECURE_NO_WARNINGS + <toolset>msvc:<define>_SCL_SECURE_NO_DEPRECATE + <toolset>msvc:<define>_CRT_SECURE_NO_WARNINGS + <toolset>msvc:<define>_CRT_SECURE_NO_DEPRECATE + <toolset>msvc:<cxxflags>"-wd4996" + <toolset>clang:<variant>debug:<cxxflags>"-fsanitize=memory" + # toolset optimizations + <toolset>gcc:<cxxflags>"-ftemplate-depth-255" + <toolset>clang:<cxxflags>"-ftemplate-depth-255" + <toolset>darwin:<cxxflags>"-ftemplate-depth-255" + <toolset>msvc:<cxxflags>"-Gy" + # linking + <link>shared:<define>BOOST_SERIALIZATION_DYN_LINK=1 + <link>shared:<define>BOOST_WSERIALIZATION_DYN_LINK=1 + $(requirements) + : # test name + $(test-name) + ] ; +} + +# Given a name of test, return the 'save' test that must be run +# before the named test, or empty string if there's no such test. +rule dependency-save-test ( test ) +{ + local m = [ MATCH (.*)load(.*) : $(test) ] ; + if $(m) + { + return $(m[1])save$(m[2]) ; + } +} + +# each of the following tests is run with each type of archive +rule run-invoke ( test-name : sources * : files * : requirements * ) +{ + local save-test = [ dependency-save-test $(test-name) ] ; + + local tests ; + tests += [ + run-template $(test-name) + : # sources + $(sources) + ../build//boost_serialization + : # input files + : # requirements + $(requirements) + <define>BOOST_LIB_DIAGNOSTIC=1 + <dependency>$(save-test) + ] ; + return $(tests) ; +} + +# each of the following tests is run with each type of archive +rule run-winvoke ( test-name : sources * : files * : requirements * ) +{ + local save-test = [ dependency-save-test $(test-name) ] ; + + local tests ; + tests += [ + run-template $(test-name) + : # sources + $(sources) + ../build//boost_serialization + ../build//boost_wserialization + : # input files + : # requirements + $(requirements) + <define>BOOST_LIB_DIAGNOSTIC=1 + # both stlport and msvc6 define iswspace + <toolset>msvc,<stdlib>stlport:<linkflags>"-force:multiple" + <dependency>$(save-test) + [ requires std_wstreambuf ] + ] ; + return $(tests) ; +} + +# for tests which don't use library code - usually just headers +rule test-bsl-run-no-lib ( test-name : sources * : requirements * ) +{ + local tests ; + tests += [ + run-template $(test-name) + : # sources + $(test-name).cpp $(sources).cpp + : # input files + : # requirements + $(requirements) + ] ; + return $(tests) ; +} + +# for tests which are run just once rather than for every archive +rule test-bsl-run ( test-name : sources * : libs * : requirements * ) +{ + local tests ; + tests += [ + run-invoke $(test-name) + : # sources + $(test-name).cpp $(sources).cpp $(libs) + : # input files + : # requirements + $(requirements) + ] ; + return $(tests) ; +} + +rule test-bsl-run_archive ( test-name : archive-name : sources * : libs * : requirements * ) { + local tests ; + switch $(archive-name) { + case "*_warchive" : + tests += [ + run-winvoke $(test-name)_$(archive-name) + : # sources + $(sources).cpp $(libs) + : # input files + : # requirements + <define>BOOST_ARCHIVE_TEST=$(archive-name).hpp + $(requirements) + ] ; + case "*" : + tests += [ + run-invoke $(test-name)_$(archive-name) + : # sources + $(sources).cpp $(libs) + : # input files + : # requirements + <define>BOOST_ARCHIVE_TEST=$(archive-name).hpp + $(requirements) + ] ; + } + return $(tests) ; +} + +rule test-bsl-run_files ( test-name : sources * : libs * : requirements * ) { + local tests ; + for local defn in $(BOOST_ARCHIVE_LIST) { + tests += [ + test-bsl-run_archive $(test-name) + : $(defn:LB) + : $(test-name) $(sources) + : $(libs) + : $(requirements) + ] ; + } + return $(tests) ; +} + +rule test-bsl-run_polymorphic_files ( test-name : sources * : libs * : requirements * ) { + local tests ; + for local defn in $(BOOST_ARCHIVE_LIST) { + ECHO polymorphic_$(defn:LB) ; + tests += [ + test-bsl-run_archive $(test-name) + : polymorphic_$(defn:LB) + : $(test-name) $(sources) + : $(libs) + : $(requirements) + ] ; + } + return $(tests) ; +} + |