[PATCH] D98726: [analyzer] Enabling MallocChecker to take up after SmartPtrModelling

Deep Majumder via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Apr 27 03:12:01 PDT 2021


RedDocMD added a comment.

Judging by this line <https://github.com/llvm/llvm-project/blob/ebe408ad8003c946ef871b955ab18e64e82697cb/clang/lib/StaticAnalyzer/Core/BugReporterVisitors.cpp#L2730> in the `LikelyFalsePositiveSuppressionBRVisitor::finalizeVisitor()` method, it seems that the bug report is squelched when the visitor encounters an  `ExplodedNode` which corresponds to a `LocationContext`, whose associated `Decl` lies in **std** namespace. I guess, by default, the option to suppress warnings from the std library is enabled. Which makes sense, except in this case since `unique_ptr` is in std and it is being used in that function, the bug report is suppressed.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D98726/new/

https://reviews.llvm.org/D98726



More information about the cfe-commits mailing list