[clang] [llvm] [analyzer] Correct Z3 test cases, fix exposed crashes (PR #146597)
Balazs Benics via llvm-commits
llvm-commits at lists.llvm.org
Wed Jul 2 05:49:51 PDT 2025
================
@@ -598,6 +598,9 @@ class SMTConv {
if (APSIntBitwidth == 1 && Ty.isNull())
return {Int.extend(Ctx.getTypeSize(Ctx.BoolTy)),
getAPSIntType(Ctx, NewInt)};
+ else if (APSIntBitwidth == 1 && !Ty.isNull())
+ return {Int.extend(Ctx.getTypeSize(getAPSIntType(Ctx, Int))),
+ getAPSIntType(Ctx, NewInt)};
----------------
steakhal wrote:
Remember to not have redundant "else" after having a "return".
https://github.com/llvm/llvm-project/pull/146597
More information about the llvm-commits
mailing list