associative_erase_if: use type_dependent_false

Avoid a sizeof(X) == 0, which is IFNDR, in favor of the dedicated
feature (type_dependent_false).

Change-Id: I38441cfe3d5c18800bf61bcdd11268cb97d40ec6
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
This commit is contained in:
Giuseppe D'Angelo 2024-12-15 13:08:25 +01:00
parent 8f958a6e2d
commit 38c51dcfc4

View File

@ -456,7 +456,7 @@ auto associative_erase_if(Container &c, Predicate &pred)
++it;
}
} else {
static_assert(sizeof(Container) == 0, "Predicate has an incompatible signature");
static_assert(type_dependent_false<Container>(), "Predicate has an incompatible signature");
}
}