diff options
Diffstat (limited to 'boost/ptr_container/ptr_sequence_adapter.hpp')
-rw-r--r-- | boost/ptr_container/ptr_sequence_adapter.hpp | 16 |
1 files changed, 7 insertions, 9 deletions
diff --git a/boost/ptr_container/ptr_sequence_adapter.hpp b/boost/ptr_container/ptr_sequence_adapter.hpp index a7717ed8e8..fceab26053 100644 --- a/boost/ptr_container/ptr_sequence_adapter.hpp +++ b/boost/ptr_container/ptr_sequence_adapter.hpp @@ -244,8 +244,7 @@ namespace ptr_container_detail void push_back( value_type x ) // strong { this->enforce_null_policy( x, "Null pointer in 'push_back()'" ); - - auto_type ptr( x ); // notrow + auto_type ptr( x, *this ); // notrow this->base().push_back( x ); // strong, commit ptr.release(); // nothrow } @@ -259,8 +258,7 @@ namespace ptr_container_detail void push_front( value_type x ) { this->enforce_null_policy( x, "Null pointer in 'push_front()'" ); - - auto_type ptr( x ); // nothrow + auto_type ptr( x, *this ); // nothrow this->base().push_front( x ); // strong, commit ptr.release(); // nothrow } @@ -275,7 +273,7 @@ namespace ptr_container_detail { BOOST_ASSERT( !this->empty() && "'pop_back()' on empty container" ); - auto_type ptr( static_cast<value_type>( this->base().back() ) ); + auto_type ptr( static_cast<value_type>(this->base().back()), *this ); // nothrow this->base().pop_back(); // nothrow return ptr_container_detail::move( ptr ); // nothrow @@ -285,7 +283,7 @@ namespace ptr_container_detail { BOOST_ASSERT( !this->empty() && "'pop_front()' on empty container" ); - auto_type ptr( static_cast<value_type>( this->base().front() ) ); + auto_type ptr( static_cast<value_type>(this->base().front()), *this ); // nothrow this->base().pop_front(); // nothrow return ptr_container_detail::move( ptr ); @@ -396,7 +394,7 @@ namespace ptr_container_detail { if( first == last ) return; - scoped_deleter sd( first, last ); // strong + scoped_deleter sd( *this, first, last ); // strong this->insert_clones_and_release( sd, before ); // strong, commit } @@ -482,7 +480,7 @@ namespace ptr_container_detail if( delete_from ) { BOOST_DEDUCED_TYPENAME base_type::scoped_deleter - deleter( from, size ); // nothrow + deleter( *this, from, size ); // nothrow this->base().insert( before.base(), from, from + size ); // strong deleter.release(); // nothrow } @@ -664,7 +662,7 @@ namespace ptr_container_detail } - void range_check_impl( iterator first, iterator last, + void range_check_impl( iterator, iterator, std::bidirectional_iterator_tag ) { /* do nothing */ } |