Erase all elements in l that satisfy the specified predicate.
Declared in <bslstl_list.h>
template<
class VALUE,
class ALLOCATOR,
class PREDICATE>
bsl::list<VALUE, ALLOCATOR>::size_type
erase_if(
list<VALUE, ALLOCATOR>& l,
PREDICATE predicate);
Return the number of elements erased.
number of elements erased
| Name | Description |
|---|---|
| l | list from which to erase elements |
| predicate | unary predicate selecting elements to erase |