mirror of
https://github.com/boostorg/smart_ptr.git
synced 2025-07-31 21:24:40 +02:00
Remove uses of boost::remove_reference
This commit is contained in:
@@ -12,9 +12,9 @@ Distributed under the Boost Software License, Version 1.0.
|
||||
#include <boost/type_traits/is_array.hpp>
|
||||
#include <boost/type_traits/is_unbounded_array.hpp>
|
||||
#include <boost/type_traits/remove_extent.hpp>
|
||||
#include <boost/type_traits/remove_reference.hpp>
|
||||
#include <memory>
|
||||
#include <utility>
|
||||
#include <type_traits>
|
||||
|
||||
namespace boost {
|
||||
|
||||
@@ -34,7 +34,7 @@ make_unique(Args&&... args)
|
||||
|
||||
template<class T>
|
||||
inline typename enable_if_<!is_array<T>::value, std::unique_ptr<T> >::type
|
||||
make_unique(typename remove_reference<T>::type&& value)
|
||||
make_unique(typename std::remove_reference<T>::type&& value)
|
||||
{
|
||||
return std::unique_ptr<T>(new T(std::move(value)));
|
||||
}
|
||||
|
@@ -12,9 +12,9 @@
|
||||
#include <boost/enable_shared_from_this.hpp>
|
||||
#include <boost/core/lightweight_test.hpp>
|
||||
#include <boost/move/unique_ptr.hpp>
|
||||
#include <boost/type_traits/remove_reference.hpp>
|
||||
#include <memory>
|
||||
#include <utility>
|
||||
#include <type_traits>
|
||||
|
||||
struct X: public boost::enable_shared_from_this< X >
|
||||
{
|
||||
@@ -88,7 +88,7 @@ template<class U, class T, class D> static void test_null_unique_ptr( boost::mov
|
||||
BOOST_TEST( sp.get() == 0 );
|
||||
BOOST_TEST( sp.use_count() == 0 );
|
||||
|
||||
sp.reset( new T, typename boost::remove_reference<D>::type() );
|
||||
sp.reset( new T, typename std::remove_reference<D>::type() );
|
||||
|
||||
BOOST_TEST( sp.get() != 0 );
|
||||
BOOST_TEST( sp.use_count() == 1 );
|
||||
|
@@ -11,9 +11,9 @@
|
||||
#include <boost/shared_ptr.hpp>
|
||||
#include <boost/enable_shared_from_this.hpp>
|
||||
#include <boost/core/lightweight_test.hpp>
|
||||
#include <boost/type_traits/remove_reference.hpp>
|
||||
#include <memory>
|
||||
#include <utility>
|
||||
#include <type_traits>
|
||||
|
||||
struct X: public boost::enable_shared_from_this< X >
|
||||
{
|
||||
@@ -87,7 +87,7 @@ template<class U, class T, class D> static void test_null_unique_ptr( std::uniqu
|
||||
BOOST_TEST( sp.get() == 0 );
|
||||
BOOST_TEST( sp.use_count() == 0 );
|
||||
|
||||
sp.reset( new T, typename boost::remove_reference<D>::type() );
|
||||
sp.reset( new T, typename std::remove_reference<D>::type() );
|
||||
|
||||
BOOST_TEST( sp.get() != 0 );
|
||||
BOOST_TEST( sp.use_count() == 1 );
|
||||
|
Reference in New Issue
Block a user