[PATCH] D99658: [analyzer] Fix clang_analyzer_getExtent for heap regions

Valeriy Savchenko via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Mar 31 06:33:25 PDT 2021


vsavchenko added inline comments.


================
Comment at: clang/test/Analysis/explain-svals.cpp:56
   clang_analyzer_explain(x); // expected-warning-re{{{{^pointer to element of type 'int' with index 0 of heap segment that starts at symbol of type 'int \*' conjured at statement 'new int \[ext\]'$}}}}
   // Sic! What gets computed is the extent of the element-region.
+  clang_analyzer_explain(clang_analyzer_getExtent(x)); // expected-warning-re{{{{^extent of heap segment that starts at symbol of type 'int \*' conjured at statement 'new int \[ext\]'$}}}}
----------------
I guess this should go now, right?


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D99658



More information about the cfe-commits mailing list