Similar to D56967, we add the existing diag::note_locked_here to tell
the user where we saw the locking that isn't matched correctly.
Details
Diff Detail
- Repository
- rC Clang
Event Timeline
include/clang/Analysis/Analyses/ThreadSafety.h | ||
---|---|---|
127 | This was supposed to mirror the following function (handleDoubleLock), where similarly Loc is the place of the issue itself and LocLocked indicates where the lock is coming from. If we want to change this, I would suggest to use present tense here: LocUnlock. The lock from LocLocked "happened in the past" (meaning earlier in the code), but the unlock "happens now" (meaning at the current location). |
include/clang/Analysis/Analyses/ThreadSafety.h | ||
---|---|---|
127 | Ah, good call on the tense of the identifier! Given that it's following a pattern, I'd say you can commit as-is. If you're similarly bothered by the name, then you could have a follow-up NFC commit that renames consistently across APIs. |
Can you rename this one to LocUnlocked to mirror the new parameter?