From aa4aa23be33de15241b378de1c561daa85dab2b4 Mon Sep 17 00:00:00 2001 From: Robert Ramey Date: Wed, 5 Apr 2006 04:52:27 +0000 Subject: [PATCH] correct for STLPort [SVN r33536] --- include/boost/serialization/hash_map.hpp | 29 ++++++++++--------- include/boost/serialization/hash_set.hpp | 36 +++++++++++++----------- include/boost/serialization/map.hpp | 33 +++++++++++----------- include/boost/serialization/set.hpp | 36 +++++++++++++----------- 4 files changed, 70 insertions(+), 64 deletions(-) diff --git a/include/boost/serialization/hash_map.hpp b/include/boost/serialization/hash_map.hpp index 55f8cc2a..c9282e36 100644 --- a/include/boost/serialization/hash_map.hpp +++ b/include/boost/serialization/hash_map.hpp @@ -28,12 +28,13 @@ // function specializations must be defined in the appropriate // namespace - boost::serialization +/* #if defined(__SGI_STL_PORT) || defined(_STLPORT_VERSION) #define STD _STLP_STD #else #define STD BOOST_STD_EXTENSION_NAMESPACE #endif - +*/ namespace boost { namespace serialization { @@ -46,14 +47,14 @@ template< > inline void save( Archive & ar, - const STD::hash_map< + const BOOST_STD_EXTENSION_NAMESPACE::hash_map< Key, HashFcn, EqualKey, Allocator > &t, const unsigned int file_version ){ boost::serialization::stl::save_hash_collection< Archive, - STD::hash_map< + BOOST_STD_EXTENSION_NAMESPACE::hash_map< Key, HashFcn, EqualKey, Allocator > >(ar, t); @@ -68,19 +69,19 @@ template< > inline void load( Archive & ar, - STD::hash_map< + BOOST_STD_EXTENSION_NAMESPACE::hash_map< Key, HashFcn, EqualKey, Allocator > &t, const unsigned int file_version ){ boost::serialization::stl::load_hash_collection< Archive, - STD::hash_map< + BOOST_STD_EXTENSION_NAMESPACE::hash_map< Key, HashFcn, EqualKey, Allocator >, boost::serialization::stl::archive_input_unique< Archive, - STD::hash_map< + BOOST_STD_EXTENSION_NAMESPACE::hash_map< Key, HashFcn, EqualKey, Allocator > > @@ -98,7 +99,7 @@ template< > inline void serialize( Archive & ar, - STD::hash_map< + BOOST_STD_EXTENSION_NAMESPACE::hash_map< Key, HashFcn, EqualKey, Allocator > &t, const unsigned int file_version @@ -116,14 +117,14 @@ template< > inline void save( Archive & ar, - const STD::hash_multimap< + const BOOST_STD_EXTENSION_NAMESPACE::hash_multimap< Key, HashFcn, EqualKey, Allocator > &t, const unsigned int file_version ){ boost::serialization::stl::save_hash_collection< Archive, - STD::hash_multimap< + BOOST_STD_EXTENSION_NAMESPACE::hash_multimap< Key, HashFcn, EqualKey, Allocator > >(ar, t); @@ -138,19 +139,19 @@ template< > inline void load( Archive & ar, - STD::hash_multimap< + BOOST_STD_EXTENSION_NAMESPACE::hash_multimap< Key, HashFcn, EqualKey, Allocator > &t, const unsigned int file_version ){ boost::serialization::stl::load_hash_collection< Archive, - STD::hash_multimap< + BOOST_STD_EXTENSION_NAMESPACE::hash_multimap< Key, HashFcn, EqualKey, Allocator >, boost::serialization::stl::archive_input_multi< Archive, - STD::hash_multimap< + BOOST_STD_EXTENSION_NAMESPACE::hash_multimap< Key, HashFcn, EqualKey, Allocator > > @@ -168,7 +169,7 @@ template< > inline void serialize( Archive & ar, - STD::hash_multimap< + BOOST_STD_EXTENSION_NAMESPACE::hash_multimap< Key, HashFcn, EqualKey, Allocator > &t, const unsigned int file_version @@ -179,7 +180,7 @@ inline void serialize( } // namespace serialization } // namespace boost -#undef STD +//#undef STD #endif // BOOST_HAS_HASH #endif // BOOST_SERIALIZATION_HASH_MAP_HPP diff --git a/include/boost/serialization/hash_set.hpp b/include/boost/serialization/hash_set.hpp index 87acc781..605d4ca0 100644 --- a/include/boost/serialization/hash_set.hpp +++ b/include/boost/serialization/hash_set.hpp @@ -26,11 +26,13 @@ // function specializations must be defined in the appropriate // namespace - boost::serialization +/* #if defined(__SGI_STL_PORT) || defined(_STLPORT_VERSION) -#define STD _STLP_STD +#define std _STLP_std #else -#define STD BOOST_STD_EXTENSION_NAMESPACE +#define std BOOST_std_EXTENSION_NAMESPACE #endif +*/ namespace boost { namespace serialization { @@ -44,14 +46,14 @@ template< > inline void save( Archive & ar, - const STD::hash_set< + const BOOST_STD_EXTENSION_NAMESPACE::hash_set< Key, HashFcn, EqualKey, Allocator > &t, const unsigned int file_version ){ boost::serialization::stl::save_hash_collection< Archive, - STD::hash_set< + BOOST_STD_EXTENSION_NAMESPACE::hash_set< Key, HashFcn, EqualKey, Allocator > >(ar, t); @@ -66,19 +68,19 @@ template< > inline void load( Archive & ar, - STD::hash_set< + BOOST_STD_EXTENSION_NAMESPACE::hash_set< Key, HashFcn, EqualKey, Allocator > &t, const unsigned int file_version ){ boost::serialization::stl::load_hash_collection< Archive, - STD::hash_set< + BOOST_STD_EXTENSION_NAMESPACE::hash_set< Key, HashFcn, EqualKey, Allocator >, boost::serialization::stl::archive_input_unique< Archive, - STD::hash_set< + BOOST_STD_EXTENSION_NAMESPACE::hash_set< Key, HashFcn, EqualKey, Allocator > > @@ -96,7 +98,7 @@ template< > inline void serialize( Archive & ar, - STD::hash_set< + BOOST_STD_EXTENSION_NAMESPACE::hash_set< Key, HashFcn, EqualKey, Allocator > &t, const unsigned int file_version @@ -114,14 +116,14 @@ template< > inline void save( Archive & ar, - const STD::hash_multiset< + const BOOST_STD_EXTENSION_NAMESPACE::hash_multiset< Key, HashFcn, EqualKey, Allocator > &t, const unsigned int file_version ){ boost::serialization::stl::save_hash_collection< Archive, - STD::hash_multiset< + BOOST_STD_EXTENSION_NAMESPACE::hash_multiset< Key, HashFcn, EqualKey, Allocator > >(ar, t); @@ -136,19 +138,19 @@ template< > inline void load( Archive & ar, - STD::hash_multiset< + BOOST_STD_EXTENSION_NAMESPACE::hash_multiset< Key, HashFcn, EqualKey, Allocator > &t, const unsigned int file_version ){ boost::serialization::stl::load_hash_collection< Archive, - STD::hash_multiset< + BOOST_STD_EXTENSION_NAMESPACE::hash_multiset< Key, HashFcn, EqualKey, Allocator >, boost::serialization::stl::archive_input_multi< Archive, - STD::hash_multiset< + BOOST_STD_EXTENSION_NAMESPACE::hash_multiset< Key, HashFcn, EqualKey, Allocator > > @@ -166,7 +168,7 @@ template< > inline void serialize( Archive & ar, - STD::hash_multiset< + BOOST_STD_EXTENSION_NAMESPACE::hash_multiset< Key, HashFcn, EqualKey, Allocator > & t, const unsigned int file_version @@ -179,10 +181,10 @@ inline void serialize( #include -BOOST_SERIALIZATION_COLLECTION_TRAITS(STD::hash_set) -BOOST_SERIALIZATION_COLLECTION_TRAITS(STD::hash_multiset) +BOOST_SERIALIZATION_COLLECTION_TRAITS(BOOST_STD_EXTENSION_NAMESPACE::hash_set) +BOOST_SERIALIZATION_COLLECTION_TRAITS(BOOST_STD_EXTENSION_NAMESPACE::hash_multiset) -#undef STD +//#undef STD #endif // BOOST_HAS_HASH #endif // BOOST_SERIALIZATION_HASH_SET_HPP diff --git a/include/boost/serialization/map.hpp b/include/boost/serialization/map.hpp index 8e8ae626..1a5c7724 100644 --- a/include/boost/serialization/map.hpp +++ b/include/boost/serialization/map.hpp @@ -28,39 +28,40 @@ // function specializations must be defined in the appropriate // namespace - boost::serialization +/* #if defined(__SGI_STL_PORT) || defined(_STLPORT_VERSION) #define STD _STLP_STD #else #define STD std #endif - +*/ namespace boost { namespace serialization { template inline void save( Archive & ar, - const STD::map &t, + const std::map &t, const unsigned int /* file_version */ ){ boost::serialization::stl::save_collection< Archive, - STD::map + std::map >(ar, t); } template inline void load( Archive & ar, - STD::map &t, + std::map &t, const unsigned int /* file_version */ ){ boost::serialization::stl::load_collection< Archive, - STD::map, + std::map, boost::serialization::stl::archive_input_unique< - Archive, STD::map >, - boost::serialization::stl::no_reserve_imp >, + boost::serialization::stl::no_reserve_imp > @@ -72,7 +73,7 @@ inline void load( template inline void serialize( Archive & ar, - STD::map &t, + std::map &t, const unsigned int file_version ){ boost::serialization::split_free(ar, t, file_version); @@ -82,29 +83,29 @@ inline void serialize( template inline void save( Archive & ar, - const STD::multimap &t, + const std::multimap &t, const unsigned int /* file_version */ ){ boost::serialization::stl::save_collection< Archive, - STD::multimap + std::multimap >(ar, t); } template inline void load( Archive & ar, - STD::multimap &t, + std::multimap &t, const unsigned int /* file_version */ ){ boost::serialization::stl::load_collection< Archive, - STD::multimap, + std::multimap, boost::serialization::stl::archive_input_multi< - Archive, STD::multimap + Archive, std::multimap >, boost::serialization::stl::no_reserve_imp< - STD::multimap + std::multimap > >(ar, t); } @@ -114,7 +115,7 @@ inline void load( template inline void serialize( Archive & ar, - STD::multimap &t, + std::multimap &t, const unsigned int file_version ){ boost::serialization::split_free(ar, t, file_version); @@ -123,6 +124,6 @@ inline void serialize( } // serialization } // namespace boost -#undef STD +//#undef STD #endif // BOOST_SERIALIZATION_MAP_HPP diff --git a/include/boost/serialization/set.hpp b/include/boost/serialization/set.hpp index 15be1c05..e5628502 100644 --- a/include/boost/serialization/set.hpp +++ b/include/boost/serialization/set.hpp @@ -24,11 +24,13 @@ #include #include +/* #if defined(__SGI_STL_PORT) || defined(_STLPORT_VERSION) #define STD _STLP_STD #else #define STD std #endif +*/ namespace boost { namespace serialization { @@ -36,27 +38,27 @@ namespace serialization { template inline void save( Archive & ar, - const STD::set &t, + const std::set &t, const unsigned int /* file_version */ ){ boost::serialization::stl::save_collection< - Archive, STD::set + Archive, std::set >(ar, t); } template inline void load( Archive & ar, - STD::set &t, + std::set &t, const unsigned int /* file_version */ ){ boost::serialization::stl::load_collection< Archive, - STD::set, + std::set, boost::serialization::stl::archive_input_unique< - Archive, STD::set + Archive, std::set >, - boost::serialization::stl::no_reserve_imp > >(ar, t); @@ -67,7 +69,7 @@ inline void load( template inline void serialize( Archive & ar, - STD::set & t, + std::set & t, const unsigned int file_version ){ boost::serialization::split_free(ar, t, file_version); @@ -77,29 +79,29 @@ inline void serialize( template inline void save( Archive & ar, - const STD::multiset &t, + const std::multiset &t, const unsigned int /* file_version */ ){ boost::serialization::stl::save_collection< Archive, - STD::multiset + std::multiset >(ar, t); } template inline void load( Archive & ar, - STD::multiset &t, + std::multiset &t, const unsigned int /* file_version */ ){ boost::serialization::stl::load_collection< Archive, - STD::multiset, + std::multiset, boost::serialization::stl::archive_input_multi< - Archive, STD::multiset + Archive, std::multiset >, boost::serialization::stl::no_reserve_imp< - STD::multiset + std::multiset > >(ar, t); } @@ -109,7 +111,7 @@ inline void load( template inline void serialize( Archive & ar, - STD::multiset & t, + std::multiset & t, const unsigned int file_version ){ boost::serialization::split_free(ar, t, file_version); @@ -120,8 +122,8 @@ inline void serialize( #include -BOOST_SERIALIZATION_COLLECTION_TRAITS(STD::set) -BOOST_SERIALIZATION_COLLECTION_TRAITS(STD::multiset) -#undef STD +BOOST_SERIALIZATION_COLLECTION_TRAITS(std::set) +BOOST_SERIALIZATION_COLLECTION_TRAITS(std::multiset) +//#undef STD #endif // BOOST_SERIALIZATION_SET_HPP