forked from boostorg/container
Fixes #187 ("flat_map::erase and unique keys")
This commit is contained in:
@@ -1265,14 +1265,14 @@ class flat_map
|
||||
(m_flat_tree.erase(dtl::force_copy<impl_const_iterator>(p)));
|
||||
}
|
||||
|
||||
//! <b>Effects</b>: Erases all elements in the container with key equivalent to x.
|
||||
//! <b>Effects</b>: If present, erases the element in the container with key equivalent to x.
|
||||
//!
|
||||
//! <b>Returns</b>: Returns the number of erased elements.
|
||||
//! <b>Returns</b>: Returns the number of erased elements (0/1).
|
||||
//!
|
||||
//! <b>Complexity</b>: Logarithmic search time plus erasure time
|
||||
//! linear to the elements with bigger keys.
|
||||
BOOST_CONTAINER_FORCEINLINE size_type erase(const key_type& x)
|
||||
{ return m_flat_tree.erase(x); }
|
||||
{ return m_flat_tree.erase_unique(x); }
|
||||
|
||||
//! <b>Effects</b>: Erases all the elements in the range [first, last).
|
||||
//!
|
||||
|
||||
Reference in New Issue
Block a user