summaryrefslogtreecommitdiff
path: root/boost/smart_ptr/detail/shared_count.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'boost/smart_ptr/detail/shared_count.hpp')
-rw-r--r--boost/smart_ptr/detail/shared_count.hpp18
1 files changed, 15 insertions, 3 deletions
diff --git a/boost/smart_ptr/detail/shared_count.hpp b/boost/smart_ptr/detail/shared_count.hpp
index 9813842300..ae7d0fb46f 100644
--- a/boost/smart_ptr/detail/shared_count.hpp
+++ b/boost/smart_ptr/detail/shared_count.hpp
@@ -54,7 +54,7 @@ namespace boost
namespace movelib
{
- template< class T, class D > class unique_ptr;
+template< class T, class D > class unique_ptr;
} // namespace movelib
@@ -118,7 +118,14 @@ private:
public:
- shared_count(): pi_(0) // nothrow
+ BOOST_CONSTEXPR shared_count(): pi_(0) // nothrow
+#if defined(BOOST_SP_ENABLE_DEBUG_HOOKS)
+ , id_(shared_count_id)
+#endif
+ {
+ }
+
+ BOOST_CONSTEXPR explicit shared_count( sp_counted_base * pi ): pi_( pi ) // nothrow
#if defined(BOOST_SP_ENABLE_DEBUG_HOOKS)
, id_(shared_count_id)
#endif
@@ -496,6 +503,11 @@ public:
return pi_? pi_->get_deleter( ti ): 0;
}
+ void * get_local_deleter( sp_typeinfo const & ti ) const
+ {
+ return pi_? pi_->get_local_deleter( ti ): 0;
+ }
+
void * get_untyped_deleter() const
{
return pi_? pi_->get_untyped_deleter(): 0;
@@ -517,7 +529,7 @@ private:
public:
- weak_count(): pi_(0) // nothrow
+ BOOST_CONSTEXPR weak_count(): pi_(0) // nothrow
#if defined(BOOST_SP_ENABLE_DEBUG_HOOKS)
, id_(weak_count_id)
#endif