[clang] [clang][analyzer] Correct SMT Layer for _BitInt cases refutations (PR #143310)

Balazs Benics via cfe-commits cfe-commits at lists.llvm.org
Wed Jun 11 01:15:46 PDT 2025


================
@@ -0,0 +1,23 @@
+// RUN: %clang_cc1 -analyze -analyzer-checker=core -w -DNO_CROSSCHECK -verify %s
+// RUN: %clang_cc1 -analyze -analyzer-checker=core -w -analyzer-config crosscheck-with-z3=true -verify %s
+// REQUIRES: z3
+
+// The SMTConv layer did not comprehend _BitInt types (because this was an
+// evolved feature) and was crashing due to needed updates in 2 places.
+// Analysis is expected to find these cases using _BitInt without crashing.
+
+_BitInt(35) a;
+int b;
----------------
steakhal wrote:

I'd suggest nesting these globals into fn parameters.

https://github.com/llvm/llvm-project/pull/143310


More information about the cfe-commits mailing list