[PATCH] D144405: [clang][pp] Handle attributes defined by plugin in __has_attribute

2023-03-13 Thread Anders Waldenborg via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG1285a495d588: [clang][pp] Handle attributes defined by plugin in __has_attribute (authored by wanders). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D144405: [clang][pp] Handle attributes defined by plugin in __has_attribute

2023-03-10 Thread Anders Waldenborg via Phabricator via cfe-commits
wanders added a comment. In D144405#4184964 , @erichkeane wrote: > So here's a potential idea for future development: It isn't > uncommon/untypical for an attribute to want to return something other than > '1', for 'version' (usually an integral

[PATCH] D144405: [clang][pp] Handle attributes defined by plugin in __has_attribute

2023-03-10 Thread Erich Keane via Phabricator via cfe-commits
erichkeane accepted this revision. erichkeane added a comment. This revision is now accepted and ready to land. So here's a potential idea for future development: It isn't uncommon/untypical for an attribute to want to return something other than '1', for 'version' (usually an integral value

[PATCH] D144405: [clang][pp] Handle attributes defined by plugin in __has_attribute

2023-03-10 Thread Anders Waldenborg via Phabricator via cfe-commits
wanders updated this revision to Diff 504152. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D144405/new/ https://reviews.llvm.org/D144405 Files: clang/docs/ReleaseNotes.rst clang/examples/Attribute/Attribute.cpp clang/lib/Basic/Attributes.cpp

[PATCH] D144405: [clang][pp] Handle attributes defined by plugin in __has_attribute

2023-03-10 Thread Anders Waldenborg via Phabricator via cfe-commits
wanders added a comment. In D144405#4184726 , @erichkeane wrote: > Looks like this doesn't compile pre-commit, though no idea if that is a > patch-stack issue. Other than test, patch looks fine. Yeah, when uploading the new commit the stack was

[PATCH] D144405: [clang][pp] Handle attributes defined by plugin in __has_attribute

2023-03-10 Thread Erich Keane via Phabricator via cfe-commits
erichkeane added a comment. Looks like this doesn't compile pre-commit, though no idea if that is a patch-stack issue. Other than test, patch looks fine. Comment at: clang/test/Frontend/plugin-attribute-pp.cpp:1 +// RUN: split-file %s %t +// RUN: %clang

[PATCH] D144405: [clang][pp] Handle attributes defined by plugin in __has_attribute

2023-03-10 Thread Anders Waldenborg via Phabricator via cfe-commits
wanders marked 2 inline comments as done. wanders added a comment. @erichkeane Patch stack now updated to include a method extraction of hasSpelling, and releasenote added. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D144405/new/

[PATCH] D144405: [clang][pp] Handle attributes defined by plugin in __has_attribute

2023-03-10 Thread Anders Waldenborg via Phabricator via cfe-commits
wanders edited the summary of this revision. wanders updated this revision to Diff 504045. wanders marked an inline comment as not done. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D144405/new/ https://reviews.llvm.org/D144405 Files:

[PATCH] D144405: [clang][pp] Handle attributes defined by plugin in __has_attribute

2023-03-06 Thread Erich Keane via Phabricator via cfe-commits
erichkeane added inline comments. Comment at: clang/lib/Basic/Attributes.cpp:46 + for (auto : getAttributePluginInstances()) { +for (auto : AttrPlugin->Spellings) + if (S.Syntax == Syntax && S.NormalizedFullName == Name) wanders wrote: > erichkeane

[PATCH] D144405: [clang][pp] Handle attributes defined by plugin in __has_attribute

2023-03-01 Thread Anders Waldenborg via Phabricator via cfe-commits
wanders added inline comments. Comment at: clang/lib/Basic/Attributes.cpp:46 + for (auto : getAttributePluginInstances()) { +for (auto : AttrPlugin->Spellings) + if (S.Syntax == Syntax && S.NormalizedFullName == Name) erichkeane wrote: > I think this

[PATCH] D144405: [clang][pp] Handle attributes defined by plugin in __has_attribute

2023-02-28 Thread Erich Keane via Phabricator via cfe-commits
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

[PATCH] D144405: [clang][pp] Handle attributes defined by plugin in __has_attribute r=aaron.ballman

2023-02-20 Thread Anders Waldenborg via Phabricator via cfe-commits
wanders created this revision. wanders added a reviewer: aaron.ballman. Herald added a subscriber: jdoerfert. Herald added a project: All. wanders requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. When using attributes by plugins (both in