erichkeane added a comment.

This needs a release note.  Otherwise I just have a preference for the 'is this 
spelling/syntax combo provided by this attribute' being in the plugin 
infrastructure.  It DOES make me wonder however, what happens if TWO plugins 
provide a different 'true' answer for those?



================
Comment at: clang/lib/Basic/Attributes.cpp:40
 
   int res = hasAttributeImpl(Syntax, Name, ScopeName, Target, LangOpts);
   if (res)
----------------
Ah, I see what you've done here.  I guess that is OK on the other patch then.


================
Comment at: clang/lib/Basic/Attributes.cpp:46
+  for (auto &AttrPlugin : getAttributePluginInstances()) {
+    for (auto &S : AttrPlugin->Spellings)
+      if (S.Syntax == Syntax && S.NormalizedFullName == Name)
----------------
I think this should be a property of the AttributePlugin type, where you send 
it the Syntax/Name and it checks to see if it is provided. 


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D144405

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

Reply via email to