[PATCH] D73720: [Analyzer] Use note tags to track container begin and and changes
Balogh, Ádám via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Mon Mar 16 12:35:06 PDT 2020
baloghadamsoftware marked an inline comment as done.
baloghadamsoftware added inline comments.
================
Comment at: clang/lib/StaticAnalyzer/Checkers/ContainerModeling.cpp:713
+ StringRef Name;
+ if (const auto *DRE = dyn_cast<DeclRefExpr>(ContE->IgnoreParenCasts())) {
+ Name = DRE->getDecl()->getName();
----------------
NoQ wrote:
> Hmm, i think you should instead look at `ContReg`, i.e. whether it's a non-anonymous `VarRegion` or a `FieldRegion` or something like that (in other patches as well). It would work more often and it'll transparently handle references.
Unfortunately it is a `SymRegion` so it does not work :-( (Even using `getMostDerivedRegion()` does not help.)
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D73720/new/
https://reviews.llvm.org/D73720
More information about the cfe-commits
mailing list