diff options
Diffstat (limited to 'boost/serialization/detail')
4 files changed, 10 insertions, 36 deletions
diff --git a/boost/serialization/detail/is_default_constructible.hpp b/boost/serialization/detail/is_default_constructible.hpp index d928e69341..451cca4d6f 100644 --- a/boost/serialization/detail/is_default_constructible.hpp +++ b/boost/serialization/detail/is_default_constructible.hpp @@ -16,7 +16,10 @@ // See http://www.boost.org for updates, documentation, and revision history. -#ifndef BOOST_NO_CXX11_HDR_TYPE_TRAITS +#include <boost/config.hpp> + +#if defined(_LIBCPP_VERSION) && (_LIBCPP_VERSION >= 1101) \ +|| ! defined(BOOST_NO_CXX11_HDR_TYPE_TRAITS) #include <type_traits> namespace boost{ namespace serialization { diff --git a/boost/serialization/detail/shared_count_132.hpp b/boost/serialization/detail/shared_count_132.hpp index a63e48849b..a5872557cf 100644 --- a/boost/serialization/detail/shared_count_132.hpp +++ b/boost/serialization/detail/shared_count_132.hpp @@ -45,11 +45,6 @@ namespace std{ } // namespace std #endif -#ifdef __BORLANDC__ -# pragma warn -8026 // Functions with excep. spec. are not expanded inline -# pragma warn -8027 // Functions containing try are not expanded inline -#endif - namespace boost_132 { // Debug hooks @@ -71,10 +66,6 @@ void sp_array_destructor_hook(void * px); // Hence, the temporary #pragma option -pc below. The version // check is deliberately conservative. -#if defined(__BORLANDC__) && __BORLANDC__ == 0x551 -# pragma option push -pc -#endif - class bad_weak_ptr: public std::exception { public: @@ -85,10 +76,6 @@ public: } }; -#if defined(__BORLANDC__) && __BORLANDC__ == 0x551 -# pragma option pop -#endif - namespace detail{ class sp_counted_base @@ -201,12 +188,12 @@ public: #if defined(BOOST_SP_ENABLE_DEBUG_HOOKS) -template<class T> void cbi_call_constructor_hook(sp_counted_base * pn, T * px, boost::checked_deleter< T > const &, int) +template<class T> void cbi_call_constructor_hook(sp_counted_base * pn, T * px, boost::checked_deleter< T > const &) { boost::sp_scalar_constructor_hook(px, sizeof(T), pn); } -template<class T> void cbi_call_constructor_hook(sp_counted_base *, T * px, boost::checked_array_deleter< T > const &, int) +template<class T> void cbi_call_constructor_hook(sp_counted_base *, T * px, boost::checked_array_deleter< T > const &) { boost::sp_array_constructor_hook(px); } @@ -215,12 +202,12 @@ template<class P, class D> void cbi_call_constructor_hook(sp_counted_base *, P c { } -template<class T> void cbi_call_destructor_hook(sp_counted_base * pn, T * px, boost::checked_deleter< T > const &, int) +template<class T> void cbi_call_destructor_hook(sp_counted_base * pn, T * px, boost::checked_deleter< T > const &) { boost::sp_scalar_destructor_hook(px, sizeof(T), pn); } -template<class T> void cbi_call_destructor_hook(sp_counted_base *, T * px, boost::checked_array_deleter< T > const &, int) +template<class T> void cbi_call_destructor_hook(sp_counted_base *, T * px, boost::checked_array_deleter< T > const &) { boost::sp_array_destructor_hook(px); } @@ -561,9 +548,4 @@ inline shared_count::shared_count(weak_count const & r): pi_(r.pi_) BOOST_SERIALIZATION_ASSUME_ABSTRACT(boost_132::detail::sp_counted_base) -#ifdef __BORLANDC__ -# pragma warn .8027 // Functions containing try are not expanded inline -# pragma warn .8026 // Functions with excep. spec. are not expanded inline -#endif - #endif // #ifndef BOOST_DETAIL_SHARED_COUNT_HPP_INCLUDED diff --git a/boost/serialization/detail/shared_ptr_132.hpp b/boost/serialization/detail/shared_ptr_132.hpp index 969b53a77b..ee98b7b944 100644 --- a/boost/serialization/detail/shared_ptr_132.hpp +++ b/boost/serialization/detail/shared_ptr_132.hpp @@ -120,13 +120,8 @@ public: { } -#if BOOST_WORKAROUND( __BORLANDC__, BOOST_TESTED_AT( 0x564) ) template<class Y> explicit shared_ptr(Y * p): px(p), pn(p, boost::checked_deleter<Y>()) // Y must be complete -#else - template<class Y> - explicit shared_ptr(Y * p): px(p), pn(p, boost::checked_deleter<Y>()) // Y must be complete -#endif { detail::sp_enable_shared_from_this( pn, p, p ); } @@ -145,15 +140,13 @@ public: // generated copy constructor, assignment, destructor are fine... // except that Borland C++ has a bug, and g++ with -Wsynth warns -#if defined(__BORLANDC__) || defined(__GNUC__) - +#if defined(__GNUC__) shared_ptr & operator=(shared_ptr const & r) // never throws { px = r.px; pn = r.pn; // shared_count::op= doesn't throw return *this; } - #endif template<class Y> diff --git a/boost/serialization/detail/stack_constructor.hpp b/boost/serialization/detail/stack_constructor.hpp index 70a80296b7..9027717a92 100644 --- a/boost/serialization/detail/stack_constructor.hpp +++ b/boost/serialization/detail/stack_constructor.hpp @@ -36,11 +36,7 @@ struct stack_allocate private: typedef typename boost::aligned_storage< sizeof(T), - #if BOOST_WORKAROUND(__BORLANDC__,BOOST_TESTED_AT(0x560)) - 8 - #else - boost::alignment_of<T>::value - #endif + boost::alignment_of<T>::value > type; type storage_; }; |