[PATCH] D84520: [Analyzer] Improve invalid dereference bug reporting in DereferenceChecker.

Endre Fülöp via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Aug 4 00:46:19 PDT 2020


gamesh411 added a comment.

I would add one more test for the undefined case. Like a local array variable that is uninitialized. That could mirror some of the null-dereference cases.



================
Comment at: clang/lib/StaticAnalyzer/Checkers/DereferenceChecker.cpp:135
+    DerefKindStr = "dereference of an undefined pointer value";
+    break;
+  };
----------------
balazske wrote:
> Add "results in a " here?
IMHO I would add the "results in a " part here, as this is part of the process of creating the diagnostic anyway.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D84520



More information about the cfe-commits mailing list