Clang and GCC have something like this but restricted to just comparisons, called -Wtautological-compare. I recommend turning it on for the same reasons. Although in practice it may need to be suppressed in macro-heavy or template-heavy code.
This has also caught many real world bugs in C such as https://github.com/aircrack-ng/rtl8812au/issues/308