Introduce the _Clang scoped attribute token.
authorAaron Ballman <aaron@aaronballman.com>
Fri, 9 Nov 2018 17:19:45 +0000 (17:19 +0000)
committerAaron Ballman <aaron@aaronballman.com>
Fri, 9 Nov 2018 17:19:45 +0000 (17:19 +0000)
commitc44c174246280dc7614b6591f48010858f482eb9
treeee0b46581c0d7149fdf74e5c5943b534b7fec331
parent21e7f5e24eb1fef1676d70eb013b1346482a7bac
Introduce the _Clang scoped attribute token.

Currently, we only accept clang as the scoped attribute identifier for double square bracket attributes provided by Clang, but this has the potential to conflict with user-defined macros. To help alleviate these concerns, this introduces the _Clang scoped attribute identifier as an alias for clang. It also introduces a warning with a fixit on the off chance someone attempts to use __clang__ as the scoped attribute (which is a predefined compiler identification macro).

llvm-svn: 346521
clang/include/clang/Basic/DiagnosticParseKinds.td
clang/lib/Basic/Attributes.cpp
clang/lib/Parse/ParseDeclCXX.cpp
clang/lib/Sema/ParsedAttr.cpp
clang/test/FixIt/fixit-cxx11-attributes.cpp
clang/test/Parser/cxx0x-attributes.cpp
clang/test/Preprocessor/has_attribute.cpp
clang/test/SemaCXX/attr-optnone.cpp