[PATCH] D49656: [analyzer] Add support for more pointer invalidating functions in InnerPointerChecker

Artem Dergachev via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Jul 23 18:11:51 PDT 2018


NoQ added inline comments.


================
Comment at: lib/StaticAnalyzer/Checkers/InnerPointerChecker.cpp:207-208
+
+    for (unsigned I = 0, E = FD->getNumParams(); I != E; ++I) {
+      QualType ParamTy = FD->getParamDecl(I)->getType();
+      if (!ParamTy->isReferenceType() ||
----------------
NoQ wrote:
> We need tests for operators here, due to the problem that i recently encountered in D49627: there's different numbering for arguments and parameters within in-class operators. Namely, this-argument is counted as an argument (shifting other argument indices by 1) but not as a parameter.
(i.e., tests and most likely some actual code branch)


https://reviews.llvm.org/D49656





More information about the cfe-commits mailing list