]> granicus.if.org Git - clang/commit
Add #pragma clang attribute
authorAlex Lorenz <arphaman@gmail.com>
Tue, 18 Apr 2017 14:33:39 +0000 (14:33 +0000)
committerAlex Lorenz <arphaman@gmail.com>
Tue, 18 Apr 2017 14:33:39 +0000 (14:33 +0000)
commit4bbde6cf2a280972796e32e11777eb69d466e56b
tree798ca5030e2add2471363b39e5d311e401c14265
parent6730a5e41ee7ce17daecbdf29ca50071a18eb919
Add #pragma clang attribute

This is a recommit of r300539 that was reverted in r300543 due to test failures.
The original commit message is displayed below:

The new '#pragma clang attribute' directive can be used to apply attributes to
multiple declarations. An attribute must satisfy the following conditions to
be supported by the pragma:
- It must have a subject list that's defined in the TableGen file.
- It must be documented.
- It must not be late parsed.
- It must have a GNU/C++11 spelling.

Differential Revision: https://reviews.llvm.org/D30009

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@300556 91177308-0d34-0410-b5e6-96231b3b80d8
40 files changed:
docs/LanguageExtensions.rst
include/clang/Basic/Attr.td
include/clang/Basic/AttrSubjectMatchRules.h [new file with mode: 0644]
include/clang/Basic/CMakeLists.txt
include/clang/Basic/DiagnosticGroups.td
include/clang/Basic/DiagnosticParseKinds.td
include/clang/Basic/DiagnosticSemaKinds.td
include/clang/Basic/TokenKinds.def
include/clang/Parse/CMakeLists.txt
include/clang/Parse/Parser.h
include/clang/Sema/AttributeList.h
include/clang/Sema/Sema.h
lib/Basic/Attributes.cpp
lib/Parse/ParsePragma.cpp
lib/Parse/ParseStmt.cpp
lib/Parse/Parser.cpp
lib/Sema/AttributeList.cpp
lib/Sema/Sema.cpp
lib/Sema/SemaAttr.cpp
lib/Sema/SemaDecl.cpp
lib/Sema/SemaDeclAttr.cpp
lib/Sema/SemaDeclCXX.cpp
lib/Sema/SemaDeclObjC.cpp
test/FixIt/fixit-pragma-attribute.c [new file with mode: 0644]
test/FixIt/fixit-pragma-attribute.cpp [new file with mode: 0644]
test/Misc/pragma-attribute-cxx-subject-match-rules.cpp [new file with mode: 0644]
test/Misc/pragma-attribute-cxx.cpp [new file with mode: 0644]
test/Misc/pragma-attribute-objc-subject-match-rules.m [new file with mode: 0644]
test/Misc/pragma-attribute-objc.m [new file with mode: 0644]
test/Misc/pragma-attribute-strict-subjects.c [new file with mode: 0644]
test/Misc/pragma-attribute-supported-attributes-list.test [new file with mode: 0644]
test/Parser/pragma-attribute-declspec.cpp [new file with mode: 0644]
test/Parser/pragma-attribute.cpp [new file with mode: 0644]
test/Sema/pragma-attribute-strict-subjects.c [new file with mode: 0644]
test/Sema/pragma-attribute.c [new file with mode: 0644]
test/lit.cfg
test/lit.site.cfg.in
utils/TableGen/ClangAttrEmitter.cpp
utils/TableGen/TableGen.cpp
utils/TableGen/TableGenBackends.h