[clang] [analyzer] Don't assume third iteration in loops (PR #119388)
Balazs Benics via cfe-commits
cfe-commits at lists.llvm.org
Fri Dec 13 04:58:36 PST 2024
================
@@ -2801,8 +2799,35 @@ void ExprEngine::processBranch(const Stmt *Condition,
if (StTrue && StFalse)
assert(!isa<ObjCForCollectionStmt>(Condition));
- if (StTrue)
- Builder.generateNode(StTrue, true, PredN);
+ if (StTrue) {
+ // If we are processing a loop condition where two iterations have
+ // already been completed and the the false branch is also feasible, then
----------------
steakhal wrote:
```suggestion
// already been completed and the false branch is also feasible, then
```
https://github.com/llvm/llvm-project/pull/119388
More information about the cfe-commits
mailing list