As requested by Sam McCall:
Enums (not new I guess). Typical case: if (enum < 0 || enum > MAX)
The warning strongly suggests that the enum < 0 check has no effect
(for enums with nonnegative ranges).
Clang doesn't seem to optimize such checks out though, and they seem
likely to catch bugs in some cases. Yes, only if there's UB elsewhere,
but I assume not optimizing out these checks indicates a deliberate
decision to stay somewhat compatible with a technically-incorrect
mental model.
If this is the case, should we move these to a
-Wtautological-compare-enum subcategory?
Should be Cmp per coding standards.