dset: add named erase method

This commit is contained in:
Danny Robson 2020-09-29 12:52:50 +10:00
parent 04de102789
commit 19551e30ed

View File

@ -68,7 +68,15 @@ namespace cruft::set {
///
/// Items must be in sorted order, and must be a subset of this
/// container.
void erase (std::span<ValueT const>);
void erase (std::span<ValueT const> rhs)
{
*this = *this - rhs;
}
void erase (ValueT const &val)
{
erase (std::span (&val, 1));
}
/// Tests if the list is a subset of this container.
///