[clang] [Sema] Don't assert when range checks see a float under an int cast (PR #233521)
Aaron Ballman via cfe-commits
cfe-commits at lists.llvm.org
Wed Oct 21 06:51:19 PDT 2026
================
@@ -0,0 +1,18 @@
+// RUN: %clang_cc1 -fopenmp -fopenmp-version=61 -fsyntax-only -verify %s
+// expected-no-diagnostics
+
+// Flatten may create integer comparisons from floating trip counts.
+// Guard against that to avoid assertion failures.
----------------
AaronBallman wrote:
The floating value in both of these tests is incredibly hard to spot; might be worth using `0.0` and `2.0` to make it more obvious.
https://github.com/llvm/llvm-project/pull/233521
More information about the cfe-commits
mailing list