diff --git a/include/boost/smart_ptr/allocate_local_shared_array.hpp b/include/boost/smart_ptr/allocate_local_shared_array.hpp index 019a344..d472418 100644 --- a/include/boost/smart_ptr/allocate_local_shared_array.hpp +++ b/include/boost/smart_ptr/allocate_local_shared_array.hpp @@ -10,6 +10,7 @@ Distributed under the Boost Software License, Version 1.0. #include #include +#include namespace boost { namespace detail { @@ -69,7 +70,7 @@ private: } /* detail */ template -inline typename enable_if_::value, +inline typename std::enable_if::value, local_shared_ptr >::type allocate_local_shared(const A& allocator, std::size_t count) { @@ -89,7 +90,7 @@ allocate_local_shared(const A& allocator, std::size_t count) } template -inline typename enable_if_::value, +inline typename std::enable_if::value, local_shared_ptr >::type allocate_local_shared(const A& allocator) { @@ -112,7 +113,7 @@ allocate_local_shared(const A& allocator) } template -inline typename enable_if_::value, +inline typename std::enable_if::value, local_shared_ptr >::type allocate_local_shared(const A& allocator, std::size_t count, const typename remove_extent::type& value) @@ -133,7 +134,7 @@ allocate_local_shared(const A& allocator, std::size_t count, } template -inline typename enable_if_::value, +inline typename std::enable_if::value, local_shared_ptr >::type allocate_local_shared(const A& allocator, const typename remove_extent::type& value) @@ -157,7 +158,7 @@ allocate_local_shared(const A& allocator, } template -inline typename enable_if_::value, +inline typename std::enable_if::value, local_shared_ptr >::type allocate_local_shared_noinit(const A& allocator, std::size_t count) { @@ -166,7 +167,7 @@ allocate_local_shared_noinit(const A& allocator, std::size_t count) } template -inline typename enable_if_::value, +inline typename std::enable_if::value, local_shared_ptr >::type allocate_local_shared_noinit(const A& allocator) { diff --git a/include/boost/smart_ptr/allocate_shared_array.hpp b/include/boost/smart_ptr/allocate_shared_array.hpp index 874db3e..e7ec10f 100644 --- a/include/boost/smart_ptr/allocate_shared_array.hpp +++ b/include/boost/smart_ptr/allocate_shared_array.hpp @@ -12,7 +12,6 @@ Distributed under the Boost Software License, Version 1.0. #include #include #include -#include #include #include #include @@ -258,7 +257,7 @@ private: } /* detail */ template -inline typename enable_if_::value, shared_ptr >::type +inline typename std::enable_if::value, shared_ptr >::type allocate_shared(const A& allocator, std::size_t count) { typedef typename detail::sp_array_element::type element; @@ -275,7 +274,7 @@ allocate_shared(const A& allocator, std::size_t count) } template -inline typename enable_if_::value, shared_ptr >::type +inline typename std::enable_if::value, shared_ptr >::type allocate_shared(const A& allocator) { enum { @@ -295,7 +294,7 @@ allocate_shared(const A& allocator) } template -inline typename enable_if_::value, shared_ptr >::type +inline typename std::enable_if::value, shared_ptr >::type allocate_shared(const A& allocator, std::size_t count, const typename remove_extent::type& value) { @@ -313,7 +312,7 @@ allocate_shared(const A& allocator, std::size_t count, } template -inline typename enable_if_::value, shared_ptr >::type +inline typename std::enable_if::value, shared_ptr >::type allocate_shared(const A& allocator, const typename remove_extent::type& value) { @@ -334,14 +333,14 @@ allocate_shared(const A& allocator, } template -inline typename enable_if_::value, shared_ptr >::type +inline typename std::enable_if::value, shared_ptr >::type allocate_shared_noinit(const A& allocator, std::size_t count) { return boost::allocate_shared(boost::noinit_adapt(allocator), count); } template -inline typename enable_if_::value, shared_ptr >::type +inline typename std::enable_if::value, shared_ptr >::type allocate_shared_noinit(const A& allocator) { return boost::allocate_shared(boost::noinit_adapt(allocator)); diff --git a/include/boost/smart_ptr/allocate_unique.hpp b/include/boost/smart_ptr/allocate_unique.hpp index 3e411ff..abc9f1e 100644 --- a/include/boost/smart_ptr/allocate_unique.hpp +++ b/include/boost/smart_ptr/allocate_unique.hpp @@ -14,7 +14,6 @@ Distributed under the Boost Software License, Version 1.0. #include #include #include -#include #include #include #include @@ -26,6 +25,7 @@ Distributed under the Boost Software License, Version 1.0. #include #include #include +#include namespace boost { namespace detail { @@ -354,7 +354,7 @@ private: } /* detail */ template -inline typename enable_if_::value, +inline typename std::enable_if::value, std::unique_ptr > >::type allocate_unique(const A& alloc) { @@ -364,7 +364,7 @@ allocate_unique(const A& alloc) } template -inline typename enable_if_::value, +inline typename std::enable_if::value, std::unique_ptr > >::type allocate_unique(const A& alloc, Args&&... args) { @@ -374,7 +374,7 @@ allocate_unique(const A& alloc, Args&&... args) } template -inline typename enable_if_::value, +inline typename std::enable_if::value, std::unique_ptr > >::type allocate_unique(const A& alloc, typename type_identity::type&& value) { @@ -384,7 +384,7 @@ allocate_unique(const A& alloc, typename type_identity::type&& value) } template -inline typename enable_if_::value, +inline typename std::enable_if::value, std::unique_ptr > > >::type allocate_unique_noinit(const A& alloc) { @@ -392,7 +392,7 @@ allocate_unique_noinit(const A& alloc) } template -inline typename enable_if_::value, +inline typename std::enable_if::value, std::unique_ptr > >::type allocate_unique(const A& alloc, std::size_t size) { @@ -403,7 +403,7 @@ allocate_unique(const A& alloc, std::size_t size) } template -inline typename enable_if_::value, +inline typename std::enable_if::value, std::unique_ptr::type, alloc_deleter > >::type allocate_unique(const A& alloc) @@ -415,7 +415,7 @@ allocate_unique(const A& alloc) } template -inline typename enable_if_::value, +inline typename std::enable_if::value, std::unique_ptr > > >::type allocate_unique_noinit(const A& alloc, std::size_t size) { @@ -423,7 +423,7 @@ allocate_unique_noinit(const A& alloc, std::size_t size) } template -inline typename enable_if_::value, +inline typename std::enable_if::value, std::unique_ptr::type, alloc_deleter > > >::type allocate_unique_noinit(const A& alloc) @@ -432,7 +432,7 @@ allocate_unique_noinit(const A& alloc) } template -inline typename enable_if_::value, +inline typename std::enable_if::value, std::unique_ptr > >::type allocate_unique(const A& alloc, std::size_t size, const typename remove_extent::type& value) @@ -445,7 +445,7 @@ allocate_unique(const A& alloc, std::size_t size, } template -inline typename enable_if_::value, +inline typename std::enable_if::value, std::unique_ptr::type, alloc_deleter > >::type allocate_unique(const A& alloc, diff --git a/include/boost/smart_ptr/make_local_shared_array.hpp b/include/boost/smart_ptr/make_local_shared_array.hpp index ba88c73..74d1d07 100644 --- a/include/boost/smart_ptr/make_local_shared_array.hpp +++ b/include/boost/smart_ptr/make_local_shared_array.hpp @@ -11,11 +11,12 @@ Distributed under the Boost Software License, Version 1.0. #include #include +#include namespace boost { template -inline typename enable_if_::value, +inline typename std::enable_if::value, local_shared_ptr >::type make_local_shared() { @@ -24,7 +25,7 @@ make_local_shared() } template -inline typename enable_if_::value, +inline typename std::enable_if::value, local_shared_ptr >::type make_local_shared(const typename remove_extent::type& value) { @@ -33,7 +34,7 @@ make_local_shared(const typename remove_extent::type& value) } template -inline typename enable_if_::value, +inline typename std::enable_if::value, local_shared_ptr >::type make_local_shared(std::size_t size) { @@ -42,7 +43,7 @@ make_local_shared(std::size_t size) } template -inline typename enable_if_::value, +inline typename std::enable_if::value, local_shared_ptr >::type make_local_shared(std::size_t size, const typename remove_extent::type& value) @@ -52,7 +53,7 @@ make_local_shared(std::size_t size, } template -inline typename enable_if_::value, +inline typename std::enable_if::value, local_shared_ptr >::type make_local_shared_noinit() { @@ -61,7 +62,7 @@ make_local_shared_noinit() } template -inline typename enable_if_::value, +inline typename std::enable_if::value, local_shared_ptr >::type make_local_shared_noinit(std::size_t size) { diff --git a/include/boost/smart_ptr/make_shared_array.hpp b/include/boost/smart_ptr/make_shared_array.hpp index 785eb87..cff2ee6 100644 --- a/include/boost/smart_ptr/make_shared_array.hpp +++ b/include/boost/smart_ptr/make_shared_array.hpp @@ -10,11 +10,12 @@ Distributed under the Boost Software License, Version 1.0. #include #include +#include namespace boost { template -inline typename enable_if_::value, shared_ptr >::type +inline typename std::enable_if::value, shared_ptr >::type make_shared() { return boost::allocate_shared(boost::default_allocator -inline typename enable_if_::value, shared_ptr >::type +inline typename std::enable_if::value, shared_ptr >::type make_shared(const typename remove_extent::type& value) { return boost::allocate_shared(boost::default_allocator::type& value) } template -inline typename enable_if_::value, shared_ptr >::type +inline typename std::enable_if::value, shared_ptr >::type make_shared(std::size_t size) { return boost::allocate_shared(boost::default_allocator -inline typename enable_if_::value, shared_ptr >::type +inline typename std::enable_if::value, shared_ptr >::type make_shared(std::size_t size, const typename remove_extent::type& value) { return boost::allocate_shared(boost::default_allocator::type& value) } template -inline typename enable_if_::value, shared_ptr >::type +inline typename std::enable_if::value, shared_ptr >::type make_shared_noinit() { return boost::allocate_shared_noinit(boost::default_allocator -inline typename enable_if_::value, shared_ptr >::type +inline typename std::enable_if::value, shared_ptr >::type make_shared_noinit(std::size_t size) { return boost::allocate_shared_noinit(boost::default_allocator #include #include #include @@ -19,35 +18,35 @@ Distributed under the Boost Software License, Version 1.0. namespace boost { template -inline typename enable_if_::value, std::unique_ptr >::type +inline typename std::enable_if::value, std::unique_ptr >::type make_unique() { return std::unique_ptr(new T()); } template -inline typename enable_if_::value, std::unique_ptr >::type +inline typename std::enable_if::value, std::unique_ptr >::type make_unique(Args&&... args) { return std::unique_ptr(new T(std::forward(args)...)); } template -inline typename enable_if_::value, std::unique_ptr >::type +inline typename std::enable_if::value, std::unique_ptr >::type make_unique(typename std::remove_reference::type&& value) { return std::unique_ptr(new T(std::move(value))); } template -inline typename enable_if_::value, std::unique_ptr >::type +inline typename std::enable_if::value, std::unique_ptr >::type make_unique_noinit() { return std::unique_ptr(new T); } template -inline typename enable_if_::value, +inline typename std::enable_if::value, std::unique_ptr >::type make_unique(std::size_t size) { @@ -55,7 +54,7 @@ make_unique(std::size_t size) } template -inline typename enable_if_::value, +inline typename std::enable_if::value, std::unique_ptr >::type make_unique_noinit(std::size_t size) {