Remove usage of deprecated macros

[SVN r81447]
This commit is contained in:
Marshall Clow
2012-11-20 23:06:46 +00:00
parent 546a3f0f12
commit 22e74d279c
7 changed files with 60 additions and 60 deletions

View File

@@ -165,11 +165,11 @@ struct allocator_traits
propagate_on_container_swap, boost::false_type) propagate_on_container_swap, boost::false_type)
propagate_on_container_swap; propagate_on_container_swap;
#if !defined(BOOST_NO_TEMPLATE_ALIASES) #if !defined(BOOST_NO_CXX11_TEMPLATE_ALIASES)
//C++11 //C++11
template <typename T> using rebind_alloc = typename boost::intrusive::detail::type_rebinder<Alloc, T>::type; template <typename T> using rebind_alloc = typename boost::intrusive::detail::type_rebinder<Alloc, T>::type;
template <typename T> using rebind_traits = allocator_traits< rebind_alloc<T> >; template <typename T> using rebind_traits = allocator_traits< rebind_alloc<T> >;
#else // #if !defined(BOOST_NO_TEMPLATE_ALIASES) #else // #if !defined(BOOST_NO_CXX11_TEMPLATE_ALIASES)
//Some workaround for C++03 or C++11 compilers with no template aliases //Some workaround for C++03 or C++11 compilers with no template aliases
template <typename T> template <typename T>
struct rebind_alloc : boost::intrusive::detail::type_rebinder<Alloc,T>::type struct rebind_alloc : boost::intrusive::detail::type_rebinder<Alloc,T>::type
@@ -196,7 +196,7 @@ struct allocator_traits
struct rebind_traits struct rebind_traits
: allocator_traits<typename boost::intrusive::detail::type_rebinder<Alloc, T>::type> : allocator_traits<typename boost::intrusive::detail::type_rebinder<Alloc, T>::type>
{}; {};
#endif // #if !defined(BOOST_NO_TEMPLATE_ALIASES) #endif // #if !defined(BOOST_NO_CXX11_TEMPLATE_ALIASES)
template <class T> template <class T>
struct portable_rebind_alloc struct portable_rebind_alloc
{ typedef typename boost::intrusive::detail::type_rebinder<Alloc, T>::type type; }; { typedef typename boost::intrusive::detail::type_rebinder<Alloc, T>::type type; };

View File

@@ -336,7 +336,7 @@ struct is_class< ::boost::container::container_detail::pair<T1, T2> >
: public ::boost::true_type : public ::boost::true_type
{}; {};
#ifdef BOOST_NO_RVALUE_REFERENCES #ifdef BOOST_NO_CXX11_RVALUE_REFERENCES
template<class T1, class T2> template<class T1, class T2>
struct has_move_emulation_enabled< ::boost::container::container_detail::pair<T1, T2> > struct has_move_emulation_enabled< ::boost::container::container_detail::pair<T1, T2> >

View File

@@ -47,7 +47,7 @@
//This cast is ugly but it is necessary until "perfect forwarding" //This cast is ugly but it is necessary until "perfect forwarding"
//is achieved in C++0x. Meanwhile, if we want to be able to //is achieved in C++0x. Meanwhile, if we want to be able to
//bind rvalues with non-const references, we have to be ugly //bind rvalues with non-const references, we have to be ugly
#ifndef BOOST_NO_RVALUE_REFERENCES #ifndef BOOST_NO_CXX11_RVALUE_REFERENCES
#define BOOST_CONTAINER_PP_PARAM_LIST(z, n, data) \ #define BOOST_CONTAINER_PP_PARAM_LIST(z, n, data) \
BOOST_PP_CAT(P, n) && BOOST_PP_CAT(p, n) \ BOOST_PP_CAT(P, n) && BOOST_PP_CAT(p, n) \
//! //!
@@ -55,13 +55,13 @@
#define BOOST_CONTAINER_PP_PARAM_LIST(z, n, data) \ #define BOOST_CONTAINER_PP_PARAM_LIST(z, n, data) \
const BOOST_PP_CAT(P, n) & BOOST_PP_CAT(p, n) \ const BOOST_PP_CAT(P, n) & BOOST_PP_CAT(p, n) \
//! //!
#endif //#ifndef BOOST_NO_RVALUE_REFERENCES #endif //#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES
#define BOOST_CONTAINER_PP_CONST_REF_PARAM_LIST_Q(z, n, Data) \ #define BOOST_CONTAINER_PP_CONST_REF_PARAM_LIST_Q(z, n, Data) \
const BOOST_PP_CAT(Q, n) & BOOST_PP_CAT(q, n) \ const BOOST_PP_CAT(Q, n) & BOOST_PP_CAT(q, n) \
//! //!
#ifndef BOOST_NO_RVALUE_REFERENCES #ifndef BOOST_NO_CXX11_RVALUE_REFERENCES
#define BOOST_CONTAINER_PP_PARAM(U, u) \ #define BOOST_CONTAINER_PP_PARAM(U, u) \
U && u \ U && u \
//! //!
@@ -69,22 +69,22 @@ const BOOST_PP_CAT(Q, n) & BOOST_PP_CAT(q, n) \
#define BOOST_CONTAINER_PP_PARAM(U, u) \ #define BOOST_CONTAINER_PP_PARAM(U, u) \
const U & u \ const U & u \
//! //!
#endif //#ifndef BOOST_NO_RVALUE_REFERENCES #endif //#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES
#ifndef BOOST_NO_RVALUE_REFERENCES #ifndef BOOST_NO_CXX11_RVALUE_REFERENCES
#define BOOST_CONTAINER_PP_PARAM_INIT(z, n, data) \ #define BOOST_CONTAINER_PP_PARAM_INIT(z, n, data) \
BOOST_PP_CAT(m_p, n) (::boost::forward< BOOST_PP_CAT(P, n) >( BOOST_PP_CAT(p, n) )) \ BOOST_PP_CAT(m_p, n) (::boost::forward< BOOST_PP_CAT(P, n) >( BOOST_PP_CAT(p, n) )) \
//! //!
#else //BOOST_NO_RVALUE_REFERENCES #else //BOOST_NO_CXX11_RVALUE_REFERENCES
#define BOOST_CONTAINER_PP_PARAM_INIT(z, n, data) \ #define BOOST_CONTAINER_PP_PARAM_INIT(z, n, data) \
BOOST_PP_CAT(m_p, n) (const_cast<BOOST_PP_CAT(P, n) &>(BOOST_PP_CAT(p, n))) \ BOOST_PP_CAT(m_p, n) (const_cast<BOOST_PP_CAT(P, n) &>(BOOST_PP_CAT(p, n))) \
//! //!
#endif //#ifndef BOOST_NO_RVALUE_REFERENCES #endif //#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES
#ifndef BOOST_NO_RVALUE_REFERENCES #ifndef BOOST_NO_CXX11_RVALUE_REFERENCES
#if defined(BOOST_MOVE_MSVC_10_MEMBER_RVALUE_REF_BUG) #if defined(BOOST_MOVE_MSVC_10_MEMBER_RVALUE_REF_BUG)
@@ -160,25 +160,25 @@ const BOOST_PP_CAT(Q, n) & BOOST_PP_CAT(q, n) \
#endif //defined(BOOST_MOVE_MSVC_10_MEMBER_RVALUE_REF_BUG) #endif //defined(BOOST_MOVE_MSVC_10_MEMBER_RVALUE_REF_BUG)
#else //BOOST_NO_RVALUE_REFERENCES #else //BOOST_NO_CXX11_RVALUE_REFERENCES
#define BOOST_CONTAINER_PP_PARAM_DEFINE(z, n, data) \ #define BOOST_CONTAINER_PP_PARAM_DEFINE(z, n, data) \
BOOST_PP_CAT(P, n) & BOOST_PP_CAT(m_p, n); \ BOOST_PP_CAT(P, n) & BOOST_PP_CAT(m_p, n); \
//! //!
#endif //#ifndef BOOST_NO_RVALUE_REFERENCES #endif //#ifndef BOOST_NO_CXX11_RVALUE_REFERENCES
#if !defined(BOOST_NO_RVALUE_REFERENCES) && defined(BOOST_MOVE_MSVC_10_MEMBER_RVALUE_REF_BUG) #if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) && defined(BOOST_MOVE_MSVC_10_MEMBER_RVALUE_REF_BUG)
#define BOOST_CONTAINER_PP_MEMBER_FORWARD(z, n, data) BOOST_PP_CAT(this->m_p, n).get() \ #define BOOST_CONTAINER_PP_MEMBER_FORWARD(z, n, data) BOOST_PP_CAT(this->m_p, n).get() \
//! //!
#else //!defined(BOOST_NO_RVALUE_REFERENCES) && defined(BOOST_MOVE_MSVC_10_MEMBER_RVALUE_REF_BUG) #else //!defined(BOOST_NO_CXX11_RVALUE_REFERENCES) && defined(BOOST_MOVE_MSVC_10_MEMBER_RVALUE_REF_BUG)
#define BOOST_CONTAINER_PP_MEMBER_FORWARD(z, n, data) \ #define BOOST_CONTAINER_PP_MEMBER_FORWARD(z, n, data) \
::boost::forward< BOOST_PP_CAT(P, n) >( BOOST_PP_CAT(this->m_p, n) ) \ ::boost::forward< BOOST_PP_CAT(P, n) >( BOOST_PP_CAT(this->m_p, n) ) \
//! //!
#endif //!defined(BOOST_NO_RVALUE_REFERENCES) && defined(BOOST_MOVE_MSVC_10_MEMBER_RVALUE_REF_BUG) #endif //!defined(BOOST_NO_CXX11_RVALUE_REFERENCES) && defined(BOOST_MOVE_MSVC_10_MEMBER_RVALUE_REF_BUG)
#define BOOST_CONTAINER_PP_PARAM_INC(z, n, data) \ #define BOOST_CONTAINER_PP_PARAM_INC(z, n, data) \
BOOST_PP_CAT(++this->m_p, n) \ BOOST_PP_CAT(++this->m_p, n) \

View File

@@ -90,7 +90,7 @@ struct remove_reference<T&>
typedef T type; typedef T type;
}; };
#ifndef BOOST_NO_RVALUE_REFERENCES #ifndef BOOST_NO_CXX11_RVALUE_REFERENCES
template<class T> template<class T>
struct remove_reference<T&&> struct remove_reference<T&&>

View File

@@ -13,12 +13,12 @@
#include <boost/container/detail/config_begin.hpp> #include <boost/container/detail/config_begin.hpp>
#if !defined(BOOST_NO_RVALUE_REFERENCES) && !defined(BOOST_NO_VARIADIC_TEMPLATES)\ #if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) && !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES)\
&& !defined(BOOST_INTERPROCESS_DISABLE_VARIADIC_TMPL) && !defined(BOOST_INTERPROCESS_DISABLE_VARIADIC_TMPL)
#define BOOST_CONTAINER_PERFECT_FORWARDING #define BOOST_CONTAINER_PERFECT_FORWARDING
#endif #endif
#if defined(BOOST_NO_NOEXCEPT) #if defined(BOOST_NO_CXX11_NOEXCEPT)
#define BOOST_CONTAINER_NOEXCEPT #define BOOST_CONTAINER_NOEXCEPT
#define BOOST_CONTAINER_NOEXCEPT_IF(x) #define BOOST_CONTAINER_NOEXCEPT_IF(x)
#else #else
@@ -26,7 +26,7 @@
#define BOOST_CONTAINER_NOEXCEPT_IF(x) noexcept(x) #define BOOST_CONTAINER_NOEXCEPT_IF(x) noexcept(x)
#endif #endif
#if !defined(BOOST_NO_VARIADIC_TEMPLATES) && defined(__GXX_EXPERIMENTAL_CXX0X__)\ #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) && defined(__GXX_EXPERIMENTAL_CXX0X__)\
&& (__GNUC__*10000 + __GNUC_MINOR__*100 + __GNUC_PATCHLEVEL__ < 40700) && (__GNUC__*10000 + __GNUC_MINOR__*100 + __GNUC_PATCHLEVEL__ < 40700)
#define BOOST_CONTAINER_UNIMPLEMENTED_PACK_EXPANSION_TO_FIXED_LIST #define BOOST_CONTAINER_UNIMPLEMENTED_PACK_EXPANSION_TO_FIXED_LIST
#endif #endif

View File

@@ -259,7 +259,7 @@ namespace container_detail {
//! Thanks Mathias! //! Thanks Mathias!
//With variadic templates, we need a single class to implement the trait //With variadic templates, we need a single class to implement the trait
#if !defined(BOOST_NO_VARIADIC_TEMPLATES) #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES)
template<class T, class ...Args> template<class T, class ...Args>
struct is_constructible_impl struct is_constructible_impl
@@ -290,7 +290,7 @@ namespace container_detail {
: is_constructible<T, allocator_arg_t, InnerAlloc, Args...> : is_constructible<T, allocator_arg_t, InnerAlloc, Args...>
{}; {};
#else // #if !defined(BOOST_NO_VARIADIC_TEMPLATES) #else // #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES)
//Without variadic templates, we need to use de preprocessor to generate //Without variadic templates, we need to use de preprocessor to generate
//some specializations. //some specializations.
@@ -382,14 +382,14 @@ namespace container_detail {
> >
{};*/ {};*/
#endif // #if !defined(BOOST_NO_VARIADIC_TEMPLATES) #endif // #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES)
#else // #if !defined(BOOST_NO_SFINAE_EXPR) #else // #if !defined(BOOST_NO_SFINAE_EXPR)
//Without advanced SFINAE expressions, we can't use is_constructible //Without advanced SFINAE expressions, we can't use is_constructible
//so backup to constructible_with_allocator_xxx //so backup to constructible_with_allocator_xxx
#if !defined(BOOST_NO_VARIADIC_TEMPLATES) #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES)
template < class T, class InnerAlloc, class ...Args> template < class T, class InnerAlloc, class ...Args>
struct is_constructible_with_allocator_prefix struct is_constructible_with_allocator_prefix
@@ -401,7 +401,7 @@ namespace container_detail {
: constructible_with_allocator_suffix<T> : constructible_with_allocator_suffix<T>
{};*/ {};*/
#else // #if !defined(BOOST_NO_VARIADIC_TEMPLATES) #else // #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES)
template < class T template < class T
, class InnerAlloc , class InnerAlloc
@@ -423,11 +423,11 @@ namespace container_detail {
: constructible_with_allocator_suffix<T> : constructible_with_allocator_suffix<T>
{};*/ {};*/
#endif // #if !defined(BOOST_NO_VARIADIC_TEMPLATES) #endif // #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES)
#endif // #if !defined(BOOST_NO_SFINAE_EXPR) #endif // #if !defined(BOOST_NO_SFINAE_EXPR)
#if !defined(BOOST_NO_VARIADIC_TEMPLATES) #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES)
template < typename OutermostAlloc template < typename OutermostAlloc
, typename InnerAlloc , typename InnerAlloc
@@ -489,7 +489,7 @@ inline void dispatch_uses_allocator
(outermost_alloc, p, ::boost::forward<Args>(args)...); (outermost_alloc, p, ::boost::forward<Args>(args)...);
} }
#else //#if !defined(BOOST_NO_VARIADIC_TEMPLATES) #else //#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES)
#define BOOST_PP_LOCAL_MACRO(n) \ #define BOOST_PP_LOCAL_MACRO(n) \
template < typename OutermostAlloc \ template < typename OutermostAlloc \
@@ -564,9 +564,9 @@ inline void dispatch_uses_allocator(boost::false_type uses_allocator
#define BOOST_PP_LOCAL_LIMITS (0, BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS) #define BOOST_PP_LOCAL_LIMITS (0, BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS)
#include BOOST_PP_LOCAL_ITERATE() #include BOOST_PP_LOCAL_ITERATE()
#endif //#if !defined(BOOST_NO_VARIADIC_TEMPLATES) #endif //#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES)
#if !defined(BOOST_NO_VARIADIC_TEMPLATES) #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES)
template <typename OuterAlloc, class ...InnerAllocs> template <typename OuterAlloc, class ...InnerAllocs>
class scoped_allocator_adaptor_base class scoped_allocator_adaptor_base
@@ -679,7 +679,7 @@ class scoped_allocator_adaptor_base
inner_allocator_type m_inner; inner_allocator_type m_inner;
}; };
#else //#if !defined(BOOST_NO_VARIADIC_TEMPLATES) #else //#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES)
//Let's add a dummy first template parameter to allow creating //Let's add a dummy first template parameter to allow creating
//specializations up to maximum InnerAlloc count //specializations up to maximum InnerAlloc count
@@ -829,13 +829,13 @@ class scoped_allocator_adaptor_base<OuterAlloc, true
#define BOOST_PP_LOCAL_LIMITS (1, BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS) #define BOOST_PP_LOCAL_LIMITS (1, BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS)
#include BOOST_PP_LOCAL_ITERATE() #include BOOST_PP_LOCAL_ITERATE()
#endif //#if !defined(BOOST_NO_VARIADIC_TEMPLATES) #endif //#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES)
//Specialization for adaptor without any InnerAlloc //Specialization for adaptor without any InnerAlloc
template <typename OuterAlloc> template <typename OuterAlloc>
class scoped_allocator_adaptor_base class scoped_allocator_adaptor_base
< OuterAlloc < OuterAlloc
#if defined(BOOST_NO_VARIADIC_TEMPLATES) #if defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES)
, true , true
BOOST_PP_ENUM_TRAILING(BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS, BOOST_CONTAINER_PP_IDENTITY, nat) BOOST_PP_ENUM_TRAILING(BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS, BOOST_CONTAINER_PP_IDENTITY, nat)
#endif #endif
@@ -850,7 +850,7 @@ class scoped_allocator_adaptor_base
{ {
typedef scoped_allocator_adaptor_base typedef scoped_allocator_adaptor_base
<typename allocator_traits<OuterAlloc>::template portable_rebind_alloc<U>::type <typename allocator_traits<OuterAlloc>::template portable_rebind_alloc<U>::type
#if defined(BOOST_NO_VARIADIC_TEMPLATES) #if defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES)
, true , true
BOOST_PP_ENUM_TRAILING(BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS, BOOST_CONTAINER_PP_IDENTITY, container_detail::nat) BOOST_PP_ENUM_TRAILING(BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS, BOOST_CONTAINER_PP_IDENTITY, container_detail::nat)
#endif #endif
@@ -887,7 +887,7 @@ class scoped_allocator_adaptor_base
scoped_allocator_adaptor_base scoped_allocator_adaptor_base
(const scoped_allocator_adaptor_base< (const scoped_allocator_adaptor_base<
OuterA2 OuterA2
#if defined(BOOST_NO_VARIADIC_TEMPLATES) #if defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES)
, true , true
BOOST_PP_ENUM_TRAILING(BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS, BOOST_CONTAINER_PP_IDENTITY, container_detail::nat) BOOST_PP_ENUM_TRAILING(BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS, BOOST_CONTAINER_PP_IDENTITY, container_detail::nat)
#endif #endif
@@ -899,7 +899,7 @@ class scoped_allocator_adaptor_base
scoped_allocator_adaptor_base scoped_allocator_adaptor_base
(BOOST_RV_REF_BEG scoped_allocator_adaptor_base< (BOOST_RV_REF_BEG scoped_allocator_adaptor_base<
OuterA2 OuterA2
#if defined(BOOST_NO_VARIADIC_TEMPLATES) #if defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES)
, true , true
BOOST_PP_ENUM_TRAILING(BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS, BOOST_CONTAINER_PP_IDENTITY, container_detail::nat) BOOST_PP_ENUM_TRAILING(BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS, BOOST_CONTAINER_PP_IDENTITY, container_detail::nat)
#endif #endif
@@ -946,7 +946,7 @@ class scoped_allocator_adaptor_base
///@endcond ///@endcond
//Scoped allocator //Scoped allocator
#if !defined(BOOST_NO_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED) #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED)
#if !defined(BOOST_CONTAINER_UNIMPLEMENTED_PACK_EXPANSION_TO_FIXED_LIST) #if !defined(BOOST_CONTAINER_UNIMPLEMENTED_PACK_EXPANSION_TO_FIXED_LIST)
@@ -992,7 +992,7 @@ class scoped_allocator_adaptor_base
#endif // #if !defined(BOOST_CONTAINER_UNIMPLEMENTED_PACK_EXPANSION_TO_FIXED_LIST) #endif // #if !defined(BOOST_CONTAINER_UNIMPLEMENTED_PACK_EXPANSION_TO_FIXED_LIST)
#else // #if !defined(BOOST_NO_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED) #else // #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED)
template <typename OuterAlloc template <typename OuterAlloc
BOOST_PP_ENUM_TRAILING_PARAMS(BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS, class Q) BOOST_PP_ENUM_TRAILING_PARAMS(BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS, class Q)
@@ -1001,7 +1001,7 @@ class scoped_allocator_adaptor
#endif #endif
: public container_detail::scoped_allocator_adaptor_base : public container_detail::scoped_allocator_adaptor_base
<OuterAlloc <OuterAlloc
#if !defined(BOOST_NO_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED) #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED)
, InnerAllocs... , InnerAllocs...
#else #else
, true BOOST_PP_ENUM_TRAILING_PARAMS(BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS, Q) , true BOOST_PP_ENUM_TRAILING_PARAMS(BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS, Q)
@@ -1014,7 +1014,7 @@ class scoped_allocator_adaptor
/// @cond /// @cond
typedef container_detail::scoped_allocator_adaptor_base typedef container_detail::scoped_allocator_adaptor_base
<OuterAlloc <OuterAlloc
#if !defined(BOOST_NO_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED) #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED)
, InnerAllocs... , InnerAllocs...
#else #else
, true BOOST_PP_ENUM_TRAILING_PARAMS(BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS, Q) , true BOOST_PP_ENUM_TRAILING_PARAMS(BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS, Q)
@@ -1058,7 +1058,7 @@ class scoped_allocator_adaptor
{ {
typedef scoped_allocator_adaptor typedef scoped_allocator_adaptor
< typename outer_traits_type::template portable_rebind_alloc<U>::type < typename outer_traits_type::template portable_rebind_alloc<U>::type
#if !defined(BOOST_NO_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED) #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED)
, InnerAllocs... , InnerAllocs...
#else #else
BOOST_PP_ENUM_TRAILING_PARAMS(BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS, Q) BOOST_PP_ENUM_TRAILING_PARAMS(BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS, Q)
@@ -1086,7 +1086,7 @@ class scoped_allocator_adaptor
: base_type(::boost::move(other.base())) : base_type(::boost::move(other.base()))
{} {}
#if !defined(BOOST_NO_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED) #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED)
//! <b>Requires</b>: OuterAlloc shall be constructible from OuterA2. //! <b>Requires</b>: OuterAlloc shall be constructible from OuterA2.
//! //!
@@ -1097,7 +1097,7 @@ class scoped_allocator_adaptor
scoped_allocator_adaptor(BOOST_FWD_REF(OuterA2) outerAlloc, const InnerAllocs & ...innerAllocs) scoped_allocator_adaptor(BOOST_FWD_REF(OuterA2) outerAlloc, const InnerAllocs & ...innerAllocs)
: base_type(::boost::forward<OuterA2>(outerAlloc), innerAllocs...) : base_type(::boost::forward<OuterA2>(outerAlloc), innerAllocs...)
{} {}
#else // #if !defined(BOOST_NO_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED) #else // #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED)
#define BOOST_PP_LOCAL_MACRO(n) \ #define BOOST_PP_LOCAL_MACRO(n) \
template <class OuterA2> \ template <class OuterA2> \
@@ -1111,14 +1111,14 @@ class scoped_allocator_adaptor
#define BOOST_PP_LOCAL_LIMITS (0, BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS) #define BOOST_PP_LOCAL_LIMITS (0, BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS)
#include BOOST_PP_LOCAL_ITERATE() #include BOOST_PP_LOCAL_ITERATE()
#endif // #if !defined(BOOST_NO_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED) #endif // #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED)
//! <b>Requires</b>: OuterAlloc shall be constructible from OuterA2. //! <b>Requires</b>: OuterAlloc shall be constructible from OuterA2.
//! //!
//! <b>Effects</b>: initializes each allocator within the adaptor with the corresponding allocator from other. //! <b>Effects</b>: initializes each allocator within the adaptor with the corresponding allocator from other.
template <class OuterA2> template <class OuterA2>
scoped_allocator_adaptor(const scoped_allocator_adaptor<OuterA2 scoped_allocator_adaptor(const scoped_allocator_adaptor<OuterA2
#if !defined(BOOST_NO_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED) #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED)
, InnerAllocs... , InnerAllocs...
#else #else
BOOST_PP_ENUM_TRAILING_PARAMS(BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS, Q) BOOST_PP_ENUM_TRAILING_PARAMS(BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS, Q)
@@ -1133,7 +1133,7 @@ class scoped_allocator_adaptor
//! rvalue from other. //! rvalue from other.
template <class OuterA2> template <class OuterA2>
scoped_allocator_adaptor(BOOST_RV_REF_BEG scoped_allocator_adaptor<OuterA2 scoped_allocator_adaptor(BOOST_RV_REF_BEG scoped_allocator_adaptor<OuterA2
#if !defined(BOOST_NO_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED) #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED)
, InnerAllocs... , InnerAllocs...
#else #else
BOOST_PP_ENUM_TRAILING_PARAMS(BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS, Q) BOOST_PP_ENUM_TRAILING_PARAMS(BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS, Q)
@@ -1229,7 +1229,7 @@ class scoped_allocator_adaptor
const base_type &base() const { return *this; } const base_type &base() const { return *this; }
/// @endcond /// @endcond
#if !defined(BOOST_NO_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED) #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED)
//! <b>Effects</b>: //! <b>Effects</b>:
//! 1) If `uses_allocator<T, inner_allocator_type>::value` is false calls //! 1) If `uses_allocator<T, inner_allocator_type>::value` is false calls
@@ -1274,7 +1274,7 @@ class scoped_allocator_adaptor
, p, ::boost::forward<Args>(args)...); , p, ::boost::forward<Args>(args)...);
} }
#else // #if !defined(BOOST_NO_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED) #else // #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED)
//Disable this overload if the first argument is pair as some compilers have //Disable this overload if the first argument is pair as some compilers have
//overload selection problems when the first parameter is a pair. //overload selection problems when the first parameter is a pair.
@@ -1295,7 +1295,7 @@ class scoped_allocator_adaptor
#define BOOST_PP_LOCAL_LIMITS (0, BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS) #define BOOST_PP_LOCAL_LIMITS (0, BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS)
#include BOOST_PP_LOCAL_ITERATE() #include BOOST_PP_LOCAL_ITERATE()
#endif // #if !defined(BOOST_NO_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED) #endif // #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED)
template <class T1, class T2> template <class T1, class T2>
void construct(std::pair<T1,T2>* p) void construct(std::pair<T1,T2>* p)
@@ -1399,7 +1399,7 @@ class scoped_allocator_adaptor
}; };
template <typename OuterA1, typename OuterA2 template <typename OuterA1, typename OuterA2
#if !defined(BOOST_NO_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED) #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED)
, typename... InnerAllocs , typename... InnerAllocs
#else #else
BOOST_PP_ENUM_TRAILING_PARAMS(BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS, class Q) BOOST_PP_ENUM_TRAILING_PARAMS(BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS, class Q)
@@ -1407,21 +1407,21 @@ template <typename OuterA1, typename OuterA2
> >
inline bool operator==( inline bool operator==(
const scoped_allocator_adaptor<OuterA1 const scoped_allocator_adaptor<OuterA1
#if !defined(BOOST_NO_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED) #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED)
,InnerAllocs... ,InnerAllocs...
#else #else
BOOST_PP_ENUM_TRAILING_PARAMS(BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS, Q) BOOST_PP_ENUM_TRAILING_PARAMS(BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS, Q)
#endif #endif
>& a, >& a,
const scoped_allocator_adaptor<OuterA2 const scoped_allocator_adaptor<OuterA2
#if !defined(BOOST_NO_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED) #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED)
,InnerAllocs... ,InnerAllocs...
#else #else
BOOST_PP_ENUM_TRAILING_PARAMS(BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS, Q) BOOST_PP_ENUM_TRAILING_PARAMS(BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS, Q)
#endif #endif
>& b) >& b)
{ {
#if !defined(BOOST_NO_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED) #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED)
const bool has_zero_inner = sizeof...(InnerAllocs) == 0u; const bool has_zero_inner = sizeof...(InnerAllocs) == 0u;
#else #else
const bool has_zero_inner = const bool has_zero_inner =
@@ -1434,7 +1434,7 @@ inline bool operator==(
} }
template <typename OuterA1, typename OuterA2 template <typename OuterA1, typename OuterA2
#if !defined(BOOST_NO_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED) #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED)
, typename... InnerAllocs , typename... InnerAllocs
#else #else
BOOST_PP_ENUM_TRAILING_PARAMS(BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS, class Q) BOOST_PP_ENUM_TRAILING_PARAMS(BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS, class Q)
@@ -1442,14 +1442,14 @@ template <typename OuterA1, typename OuterA2
> >
inline bool operator!=( inline bool operator!=(
const scoped_allocator_adaptor<OuterA1 const scoped_allocator_adaptor<OuterA1
#if !defined(BOOST_NO_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED) #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED)
,InnerAllocs... ,InnerAllocs...
#else #else
BOOST_PP_ENUM_TRAILING_PARAMS(BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS, Q) BOOST_PP_ENUM_TRAILING_PARAMS(BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS, Q)
#endif #endif
>& a, >& a,
const scoped_allocator_adaptor<OuterA2 const scoped_allocator_adaptor<OuterA2
#if !defined(BOOST_NO_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED) #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) || defined(BOOST_CONTAINER_DOXYGEN_INVOKED)
,InnerAllocs... ,InnerAllocs...
#else #else
BOOST_PP_ENUM_TRAILING_PARAMS(BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS, Q) BOOST_PP_ENUM_TRAILING_PARAMS(BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS, Q)

View File

@@ -18,7 +18,7 @@
#include <boost/container/detail/config_begin.hpp> #include <boost/container/detail/config_begin.hpp>
#include <boost/container/detail/workaround.hpp> #include <boost/container/detail/workaround.hpp>
#if defined(BOOST_NO_VARIADIC_TEMPLATES) #if defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES)
#include <boost/container/detail/preprocessor.hpp> #include <boost/container/detail/preprocessor.hpp>
#include <boost/container/detail/type_traits.hpp> #include <boost/container/detail/type_traits.hpp>
#endif #endif
@@ -27,7 +27,7 @@ namespace boost { namespace container {
///@cond ///@cond
#if !defined(BOOST_NO_VARIADIC_TEMPLATES) #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES)
#if !defined(BOOST_CONTAINER_UNIMPLEMENTED_PACK_EXPANSION_TO_FIXED_LIST) #if !defined(BOOST_CONTAINER_UNIMPLEMENTED_PACK_EXPANSION_TO_FIXED_LIST)
@@ -45,7 +45,7 @@ namespace boost { namespace container {
#endif // #if !defined(BOOST_CONTAINER_UNIMPLEMENTED_PACK_EXPANSION_TO_FIXED_LIST) #endif // #if !defined(BOOST_CONTAINER_UNIMPLEMENTED_PACK_EXPANSION_TO_FIXED_LIST)
#else // #if !defined(BOOST_NO_VARIADIC_TEMPLATES) #else // #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES)
template <typename OuterAlloc template <typename OuterAlloc
BOOST_PP_ENUM_TRAILING( BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS BOOST_PP_ENUM_TRAILING( BOOST_CONTAINER_MAX_CONSTRUCTOR_PARAMETERS