[PATCH] D51901: Thread Safety Analysis: warnings for attributes without arguments

Josh Gao via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Sep 10 18:52:25 PDT 2018


jmgao added inline comments.


================
Comment at: include/clang/Basic/DiagnosticSemaKinds.td:3016-3017
+def warn_thread_attribute_not_on_capability_member : Warning<
+  "%0 attribute without capability arguments can only be applied in a class "
+  "annotated with 'capability' or 'scoped_lockable' attribute, but %1 isn't">,
+  InGroup<ThreadSafetyAttributes>, DefaultIgnore;
----------------
aaronpuchert wrote:
> Alternative wording: "%0 attribute without capability arguments refers to 'this', but %1 isn't annotated with 'capability' or 'scoped_lockable' attribute".
Maybe something like "implicit 'this' argument for %0 attribute isn't annotated with 'capability' or 'scoped_lockable" attribute"?


Repository:
  rC Clang

https://reviews.llvm.org/D51901





More information about the cfe-commits mailing list