[#bsl-erase_if-030] = xref:bsl.adoc[bsl]::erase_if :relfileprefix: ../ :mrdocs: Erase all elements in `ms` that satisfy `predicate`. == Synopsis Declared in `<bslstl_multiset.h>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- template< class KEY, class COMPARATOR, class ALLOCATOR, class PREDICATE> bsl::multiset<KEY, COMPARATOR, ALLOCATOR>::size_type erase_if( xref:bsl/multiset-03.adoc[multiset<KEY, COMPARATOR, ALLOCATOR>]& ms, PREDICATE predicate); ---- == Description Erase all the elements in the specified multiset `ms` that satisfy the specified predicate `predicate`. Return the number of elements erased. == Return Value number of elements erased == Parameters [cols="1,4"] |=== | Name| Description | *ms* | multiset from which to erase elements | *predicate* | unary predicate selecting elements to erase |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#