[PATCH] D12445: [Static Analyzer] Remove sinks from nullability checks.

Gábor Horváth via cfe-commits cfe-commits at lists.llvm.org
Tue Sep 1 14:26:48 PDT 2015


xazax.hun added inline comments.

================
Comment at: lib/StaticAnalyzer/Checkers/NullabilityChecker.cpp:806
@@ -690,1 +805,3 @@
 
+  ProgramStateRef State = C.getState();
+  if (State->get<PreconditionViolated>())
----------------
zaks.anna wrote:
> Maybe we should only check these at the time the bug is about to be reported.. 
> 
> That way the code would be less error prone..
This is checked before error reporting as well.
The purpose of this check at the beginning of the callbacks is optimization only.


http://reviews.llvm.org/D12445





More information about the cfe-commits mailing list