[PATCH] D49057: [analyzer] Track multiple raw pointer symbols in DanglingInternalBufferChecker

Reka Kovacs via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Sun Jul 8 10:57:50 PDT 2018

rnkovacs added inline comments.

Comment at: lib/StaticAnalyzer/Checkers/DanglingInternalBufferChecker.cpp:126
+      NewSet = F.add(NewSet, RawPtr.getAsSymbol());
+      if (!NewSet.isEmpty()) {
+        State = State->set<RawPtrMap>(ObjRegion, NewSet);
xazax.hun wrote:
> Is it possible here the set to be empty? We just added a new element to it above. Maybe turn this into an assert or just omit this if it is impossible?
I'm not sure whether `add()` can fail. I turned it into an assert now and will see if it ever fails.


More information about the cfe-commits mailing list