mirror of
https://github.com/boostorg/container.git
synced 2025-08-03 14:34:27 +02:00
Fixed wrong call to vector::merge_unique in insert_unique and used placement construction in priv_merge_in_new_buffer
This commit is contained in:
@@ -506,7 +506,7 @@ class flat_tree
|
|||||||
>::type * = 0
|
>::type * = 0
|
||||||
#endif
|
#endif
|
||||||
)
|
)
|
||||||
{ this->m_data.m_vect.merge_unique(first, last); }
|
{ this->m_data.m_vect.merge_unique(first, last, value_compare()); }
|
||||||
|
|
||||||
#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES)
|
#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES)
|
||||||
|
|
||||||
|
@@ -2301,7 +2301,8 @@ class vector
|
|||||||
}
|
}
|
||||||
//maintain stability moving external values only if they are strictly less
|
//maintain stability moving external values only if they are strictly less
|
||||||
else if(comp(*first, *pbeg)) {
|
else if(comp(*first, *pbeg)) {
|
||||||
*d_first = ::boost::move(*first);
|
allocator_traits_type::construct( this->m_holder.alloc(), d_first, ::boost::move(*first) );
|
||||||
|
new_values_destroyer.increment_size(1u);
|
||||||
++first;
|
++first;
|
||||||
--n;
|
--n;
|
||||||
++d_first;
|
++d_first;
|
||||||
@@ -2312,7 +2313,8 @@ class vector
|
|||||||
--added;
|
--added;
|
||||||
}
|
}
|
||||||
else{
|
else{
|
||||||
*d_first = ::boost::move(*pbeg);
|
allocator_traits_type::construct( this->m_holder.alloc(), d_first, ::boost::move(*pbeg) );
|
||||||
|
new_values_destroyer.increment_size(1u);
|
||||||
++pbeg;
|
++pbeg;
|
||||||
++d_first;
|
++d_first;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user