...one of the most highly
regarded and expertly designed C++ library projects in the
world.
— Herb Sutter and Andrei
Alexandrescu, C++
Coding Standards
Erase an element preserving order.
std::size_t stable_erase( string_view key);
Remove the element which matches key
,
if it exists. All references and iterators are invalidated. The relative
order of remaining elements is preserved.
Linear in size()
.
No-throw guarantee.
The number of elements removed, which will be either 0 or 1.
Name |
Description |
---|---|
|
The key to match. |