[#bsl-list-054-unique-04] = xref:bsl.adoc[bsl]::xref:bsl/list-054.adoc[list]::unique :relfileprefix: ../../ :mrdocs: Erase consecutive elements that compare equal under `binaryPredicate`. == Synopsis Declared in `<bslstl_list.h>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- template<class EQ_PREDICATE> void unique(EQ_PREDICATE binaryPredicate); ---- == Description Keep the first element of every consecutive group for which `binaryPredicate` returns `true` for any two consecutive elements in the group. == Parameters [cols="1,4"] |=== | Name| Description | *binaryPredicate* | predicate comparing consecutive elements |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#