[Sema] add warning for tautological FP compare with literal
If we are equality comparing an FP literal with a value cast from a type where the literal can't be represented, that's known true or false and probably a programmer error. Fixes issue #54222. https://github.com/llvm/llvm-project/issues/54222 Note - I added the optimizer change with: 9397bdc6 ...and as discussed in the post-commit comments, that transform might be too dangerous without this warning in place, so it was reverted to allow this change first. Differential Revision: https://reviews.llvm.org/D121306
Loading
Please sign in to comment