aaronpuchert added inline comments.

================
Comment at: clang/lib/Analysis/ThreadSafety.cpp:2199
+    // Take the exclusive capability to reduce further warnings.
+    return B.kind() == LK_Exclusive;
+  } else {
----------------
aaron.ballman wrote:
> The old code was looking at `LDat1.kind() != LK_Exclusive` -- any reason this 
> isn't `A.kind() != LK_Exclusive` as well?
Given that both should be equivalent (knowing `A.kind() != B.kind()` and that 
there are just two kinds), I thought this condition fits better to the comment: 
we select the lock that's exclusive, instead of not selecting the lock that's 
not exclusive.

But I don't have a problem with `A.kind() != LK_Exclusive` if that sounds more 
natural to you.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D102025

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

Reply via email to