[clang] [NFC][analyzer] Spread use of 'Expr*' instead of 'Stmt*' (PR #188319)
Donát Nagy via cfe-commits
cfe-commits at lists.llvm.org
Mon Mar 30 02:42:25 PDT 2026
================
@@ -32,6 +32,12 @@ class SymbolReaper;
/// This allows the environment to manage context-sensitive bindings,
/// which is essentially for modeling recursive function analysis, among
/// other things.
+/// FIXME: Use 'Expr' instead of 'Stmt' because associating a result with a
+/// non-expression statement does not make sense. Currently the environment
+/// never contains non-expression statements; and there is only one
+/// easy-to-eliminate hack in 'processCallExit' and 'Environment::getSVal' that
+/// constructs and handles 'EnvironmentEntry' instances with a 'ReturnStmt' as
+/// the 'first' part.
----------------
NagyDonat wrote:
A few days ago I discussed this with Gábor Tóthvári (@tigbr) and he will start implementing these FIXMEs as soon as this PR is merged. (As a student developer, Gábor Tóthvári is currently working on introducing a more efficient implementation for the `Environment` type – which could hopefully lead to the elimination of the node reclamation process – so he is familiar with these parts of the source code.)
https://github.com/llvm/llvm-project/pull/188319
More information about the cfe-commits
mailing list