xazax.hun marked 4 inline comments as done.
xazax.hun added inline comments.


================
Comment at: clang/lib/StaticAnalyzer/Checkers/FuchsiaHandleChecker.cpp:133-135
+  static HandleState getWithoutError(HandleState S) {
+    return HandleState(S.K, nullptr);
+  }
----------------
xazax.hun wrote:
> NoQ wrote:
> > It already makes me mildly uncomfortable that our data is not "normalized", 
> > i.e. you can indicate the Schrödinger state by either adding an error 
> > symbol or changing from `Allocated` to `MaybeAllocated`. Do i understand it 
> > correctly that you're now adding a special state where the handle is still 
> > `MaybeAllocated` but there's no error symbol? Please comment this up.
> Yeah, the reason is that, when the handle is a return value, we have no idea 
> where the error symbol is. This would only happen if someone do not follow 
> the API guidelines (in Fuchsia). I'll add a comment.
Sorry, I was hasty and my head was full of another patch. It has nothing to do 
with returned handles. I used this to control when to let some symbols die. But 
with your suggested approach this factory is no longer needed.


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

https://reviews.llvm.org/D73151



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to