[clang] [analyzer] Suppress out of bounds reports after weak loop assumptions (PR #109804)
via cfe-commits
cfe-commits at lists.llvm.org
Tue Sep 24 16:14:13 PDT 2024
=?utf-8?q?DonĂ¡t?= Nagy <donat.nagy at ericsson.com>
Message-ID:
In-Reply-To: <llvm.org/llvm/llvm-project/pull/109804 at github.com>
================
@@ -121,6 +121,25 @@ struct EvalCallOptions {
EvalCallOptions() {}
};
+/// Simple control flow statements like `if` only produce a single state split,
+/// so the fact that they are included in the source code implies that both
+/// branches are possible (at least under some conditions) and the analyzer can
----------------
isuckatcs wrote:
> Simple control flow statements like `if` [...] so the fact that they are included in the source code implies that both branches are possible
I'm not sure I understand how you meant this. Even if only one branch is possible, the `if` is included in the source code, AST and CFG. (e.g.: `if (true) { 1; } else { 0; }`)
https://github.com/llvm/llvm-project/pull/109804
More information about the cfe-commits
mailing list