mirror of
https://github.com/boostorg/smart_ptr.git
synced 2025-07-30 12:47:28 +02:00
Remove boost::detail::sp_nullptr_t
This commit is contained in:
@ -9,7 +9,6 @@ Distributed under the Boost Software License, Version 1.0.
|
|||||||
#define BOOST_SMART_PTR_ALLOCATE_UNIQUE_HPP
|
#define BOOST_SMART_PTR_ALLOCATE_UNIQUE_HPP
|
||||||
|
|
||||||
#include <boost/smart_ptr/detail/sp_noexcept.hpp>
|
#include <boost/smart_ptr/detail/sp_noexcept.hpp>
|
||||||
#include <boost/smart_ptr/detail/sp_nullptr_t.hpp>
|
|
||||||
#include <boost/core/allocator_access.hpp>
|
#include <boost/core/allocator_access.hpp>
|
||||||
#include <boost/core/alloc_construct.hpp>
|
#include <boost/core/alloc_construct.hpp>
|
||||||
#include <boost/core/empty_value.hpp>
|
#include <boost/core/empty_value.hpp>
|
||||||
@ -27,6 +26,7 @@ Distributed under the Boost Software License, Version 1.0.
|
|||||||
#include <boost/config.hpp>
|
#include <boost/config.hpp>
|
||||||
#include <memory>
|
#include <memory>
|
||||||
#include <utility>
|
#include <utility>
|
||||||
|
#include <cstddef>
|
||||||
|
|
||||||
namespace boost {
|
namespace boost {
|
||||||
namespace detail {
|
namespace detail {
|
||||||
|
@ -1,41 +0,0 @@
|
|||||||
#ifndef BOOST_SMART_PTR_DETAIL_SP_NULLPTR_T_HPP_INCLUDED
|
|
||||||
#define BOOST_SMART_PTR_DETAIL_SP_NULLPTR_T_HPP_INCLUDED
|
|
||||||
|
|
||||||
// MS compatible compilers support #pragma once
|
|
||||||
|
|
||||||
#if defined(_MSC_VER) && (_MSC_VER >= 1020)
|
|
||||||
# pragma once
|
|
||||||
#endif
|
|
||||||
|
|
||||||
// detail/sp_nullptr_t.hpp
|
|
||||||
//
|
|
||||||
// Copyright 2013 Peter Dimov
|
|
||||||
//
|
|
||||||
// Distributed under the Boost Software License, Version 1.0.
|
|
||||||
// See accompanying file LICENSE_1_0.txt or copy at
|
|
||||||
// http://www.boost.org/LICENSE_1_0.txt
|
|
||||||
|
|
||||||
#include <boost/config.hpp>
|
|
||||||
#include <cstddef>
|
|
||||||
|
|
||||||
namespace boost
|
|
||||||
{
|
|
||||||
|
|
||||||
namespace detail
|
|
||||||
{
|
|
||||||
|
|
||||||
#if !defined( BOOST_NO_CXX11_DECLTYPE ) && ( ( defined( __clang__ ) && !defined( _LIBCPP_VERSION ) ) || defined( __INTEL_COMPILER ) )
|
|
||||||
|
|
||||||
typedef decltype(nullptr) sp_nullptr_t;
|
|
||||||
|
|
||||||
#else
|
|
||||||
|
|
||||||
typedef std::nullptr_t sp_nullptr_t;
|
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
||||||
} // namespace detail
|
|
||||||
|
|
||||||
} // namespace boost
|
|
||||||
|
|
||||||
#endif // #ifndef BOOST_SMART_PTR_DETAIL_SP_NULLPTR_T_HPP_INCLUDED
|
|
@ -14,7 +14,6 @@
|
|||||||
//
|
//
|
||||||
|
|
||||||
#include <boost/smart_ptr/detail/sp_convertible.hpp>
|
#include <boost/smart_ptr/detail/sp_convertible.hpp>
|
||||||
#include <boost/smart_ptr/detail/sp_nullptr_t.hpp>
|
|
||||||
#include <boost/smart_ptr/detail/sp_noexcept.hpp>
|
#include <boost/smart_ptr/detail/sp_noexcept.hpp>
|
||||||
#include <boost/assert.hpp>
|
#include <boost/assert.hpp>
|
||||||
#include <boost/config.hpp>
|
#include <boost/config.hpp>
|
||||||
@ -22,6 +21,7 @@
|
|||||||
|
|
||||||
#include <functional> // for std::less
|
#include <functional> // for std::less
|
||||||
#include <iosfwd> // for std::basic_ostream
|
#include <iosfwd> // for std::basic_ostream
|
||||||
|
#include <cstddef>
|
||||||
|
|
||||||
namespace boost
|
namespace boost
|
||||||
{
|
{
|
||||||
|
@ -10,12 +10,10 @@
|
|||||||
//
|
//
|
||||||
// See http://www.boost.org/libs/smart_ptr/ for documentation.
|
// See http://www.boost.org/libs/smart_ptr/ for documentation.
|
||||||
|
|
||||||
#include <boost/config.hpp>
|
|
||||||
#include <boost/assert.hpp>
|
|
||||||
#include <boost/core/checked_delete.hpp>
|
|
||||||
#include <boost/smart_ptr/detail/sp_nullptr_t.hpp>
|
|
||||||
#include <boost/smart_ptr/detail/sp_noexcept.hpp>
|
#include <boost/smart_ptr/detail/sp_noexcept.hpp>
|
||||||
|
#include <boost/core/checked_delete.hpp>
|
||||||
|
#include <boost/assert.hpp>
|
||||||
|
#include <boost/config.hpp>
|
||||||
#include <boost/config/workaround.hpp>
|
#include <boost/config/workaround.hpp>
|
||||||
|
|
||||||
#include <cstddef> // for std::ptrdiff_t
|
#include <cstddef> // for std::ptrdiff_t
|
||||||
|
@ -10,13 +10,13 @@
|
|||||||
//
|
//
|
||||||
// See http://www.boost.org/libs/smart_ptr/ for documentation.
|
// See http://www.boost.org/libs/smart_ptr/ for documentation.
|
||||||
|
|
||||||
#include <boost/config.hpp>
|
|
||||||
#include <boost/assert.hpp>
|
|
||||||
#include <boost/core/checked_delete.hpp>
|
|
||||||
#include <boost/smart_ptr/detail/sp_nullptr_t.hpp>
|
|
||||||
#include <boost/smart_ptr/detail/sp_disable_deprecated.hpp>
|
#include <boost/smart_ptr/detail/sp_disable_deprecated.hpp>
|
||||||
#include <boost/smart_ptr/detail/sp_noexcept.hpp>
|
#include <boost/smart_ptr/detail/sp_noexcept.hpp>
|
||||||
|
#include <boost/core/checked_delete.hpp>
|
||||||
|
#include <boost/assert.hpp>
|
||||||
#include <boost/config/workaround.hpp>
|
#include <boost/config/workaround.hpp>
|
||||||
|
#include <boost/config.hpp>
|
||||||
|
#include <cstddef>
|
||||||
|
|
||||||
#ifndef BOOST_NO_AUTO_PTR
|
#ifndef BOOST_NO_AUTO_PTR
|
||||||
# include <memory> // for std::auto_ptr
|
# include <memory> // for std::auto_ptr
|
||||||
|
@ -14,22 +14,17 @@
|
|||||||
// See http://www.boost.org/libs/smart_ptr/ for documentation.
|
// See http://www.boost.org/libs/smart_ptr/ for documentation.
|
||||||
//
|
//
|
||||||
|
|
||||||
#include <boost/config.hpp> // for broken compiler workarounds
|
|
||||||
|
|
||||||
#include <memory> // TR1 cyclic inclusion fix
|
|
||||||
|
|
||||||
#include <boost/assert.hpp>
|
|
||||||
#include <boost/core/checked_delete.hpp>
|
|
||||||
|
|
||||||
#include <boost/smart_ptr/shared_ptr.hpp>
|
#include <boost/smart_ptr/shared_ptr.hpp>
|
||||||
#include <boost/smart_ptr/detail/shared_count.hpp>
|
#include <boost/smart_ptr/detail/shared_count.hpp>
|
||||||
#include <boost/smart_ptr/detail/sp_nullptr_t.hpp>
|
|
||||||
#include <boost/smart_ptr/detail/sp_noexcept.hpp>
|
#include <boost/smart_ptr/detail/sp_noexcept.hpp>
|
||||||
|
#include <boost/core/checked_delete.hpp>
|
||||||
|
#include <boost/assert.hpp>
|
||||||
|
#include <boost/config.hpp>
|
||||||
#include <boost/config/workaround.hpp>
|
#include <boost/config/workaround.hpp>
|
||||||
|
|
||||||
#include <cstddef> // for std::ptrdiff_t
|
|
||||||
#include <algorithm> // for std::swap
|
#include <algorithm> // for std::swap
|
||||||
#include <functional> // for std::less
|
#include <functional> // for std::less
|
||||||
|
#include <cstddef> // for std::ptrdiff_t
|
||||||
|
|
||||||
namespace boost
|
namespace boost
|
||||||
{
|
{
|
||||||
|
@ -16,7 +16,6 @@
|
|||||||
|
|
||||||
#include <boost/smart_ptr/detail/shared_count.hpp>
|
#include <boost/smart_ptr/detail/shared_count.hpp>
|
||||||
#include <boost/smart_ptr/detail/sp_convertible.hpp>
|
#include <boost/smart_ptr/detail/sp_convertible.hpp>
|
||||||
#include <boost/smart_ptr/detail/sp_nullptr_t.hpp>
|
|
||||||
#include <boost/smart_ptr/detail/sp_disable_deprecated.hpp>
|
#include <boost/smart_ptr/detail/sp_disable_deprecated.hpp>
|
||||||
#include <boost/smart_ptr/detail/sp_noexcept.hpp>
|
#include <boost/smart_ptr/detail/sp_noexcept.hpp>
|
||||||
#include <boost/core/checked_delete.hpp>
|
#include <boost/core/checked_delete.hpp>
|
||||||
|
@ -222,7 +222,7 @@ static void deleter_constructor()
|
|||||||
|
|
||||||
// nullptr_deleter_constructor
|
// nullptr_deleter_constructor
|
||||||
|
|
||||||
void deleter3( boost::detail::sp_nullptr_t )
|
void deleter3( std::nullptr_t )
|
||||||
{
|
{
|
||||||
++m;
|
++m;
|
||||||
}
|
}
|
||||||
|
@ -9,7 +9,6 @@
|
|||||||
//
|
//
|
||||||
|
|
||||||
#include <boost/shared_ptr.hpp>
|
#include <boost/shared_ptr.hpp>
|
||||||
#include <boost/smart_ptr/detail/sp_nullptr_t.hpp>
|
|
||||||
#include <boost/core/lightweight_test.hpp>
|
#include <boost/core/lightweight_test.hpp>
|
||||||
#include <cstddef>
|
#include <cstddef>
|
||||||
#include <memory>
|
#include <memory>
|
||||||
@ -36,7 +35,7 @@ private:
|
|||||||
|
|
||||||
int X::instances = 0;
|
int X::instances = 0;
|
||||||
|
|
||||||
void f( boost::detail::sp_nullptr_t )
|
void f( std::nullptr_t )
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user