X-Git-Url: https://git.donarmstrong.com/?p=rsem.git;a=blobdiff_plain;f=boost%2Fsmart_ptr%2Fdetail%2Fsp_counted_impl.hpp;h=d15cd3cf1cd38d4898e933de2931acb52e8444f8;hp=397421ae9fae05e5efa6d081333a86ed5f6e1dcf;hb=2d71eb92104693ca9baa5a2e1c23eeca776d8fd3;hpb=da57529b92adbb7ae74a89861cb39fb35ac7c62d diff --git a/boost/smart_ptr/detail/sp_counted_impl.hpp b/boost/smart_ptr/detail/sp_counted_impl.hpp index 397421a..d15cd3c 100644 --- a/boost/smart_ptr/detail/sp_counted_impl.hpp +++ b/boost/smart_ptr/detail/sp_counted_impl.hpp @@ -83,6 +83,11 @@ public: return 0; } + virtual void * get_untyped_deleter() + { + return 0; + } + #if defined(BOOST_SP_USE_STD_ALLOCATOR) void * operator new( std::size_t ) @@ -135,7 +140,11 @@ public: // pre: d(p) must not throw - sp_counted_impl_pd( P p, D d ): ptr(p), del(d) + sp_counted_impl_pd( P p, D & d ): ptr( p ), del( d ) + { + } + + sp_counted_impl_pd( P p ): ptr( p ), del() { } @@ -149,6 +158,11 @@ public: return ti == BOOST_SP_TYPEID(D)? &reinterpret_cast( del ): 0; } + virtual void * get_untyped_deleter() + { + return &reinterpret_cast( del ); + } + #if defined(BOOST_SP_USE_STD_ALLOCATOR) void * operator new( std::size_t ) @@ -195,7 +209,11 @@ public: // pre: d( p ) must not throw - sp_counted_impl_pda( P p, D d, A a ): p_( p ), d_( d ), a_( a ) + sp_counted_impl_pda( P p, D & d, A a ): p_( p ), d_( d ), a_( a ) + { + } + + sp_counted_impl_pda( P p, A a ): p_( p ), d_(), a_( a ) { } @@ -218,6 +236,11 @@ public: { return ti == BOOST_SP_TYPEID( D )? &reinterpret_cast( d_ ): 0; } + + virtual void * get_untyped_deleter() + { + return &reinterpret_cast( d_ ); + } }; #ifdef __CODEGUARD__