[PATCH] D49885: Thread safety analysis: Allow relockable scopes
Aaron Puchert via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue Aug 14 16:57:05 PDT 2018
aaronpuchert marked 4 inline comments as done.
aaronpuchert added a comment.
@aaron.ballman Maybe you can have a look again — this is much more elegant. I'm not sure why I didn't see this in the first place.
================
Comment at: test/SemaCXX/warn-thread-safety-analysis.cpp:2765-2768
+ // Debatable that there is no warning. Currently we don't track in the scoped
+ // object whether it is active, but just check if the contained locks can be
+ // reacquired. Here they can, because mu has been unlocked manually.
+ scope.Lock();
----------------
I have a local patch that addresses this, but I think it should be discussed separately as it introduces additional changes.
Repository:
rC Clang
https://reviews.llvm.org/D49885
More information about the cfe-commits
mailing list