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