diff options
author | Richard Smith <richard-llvm@metafoo.co.uk> | 2013-01-29 10:02:16 +0000 |
---|---|---|
committer | Richard Smith <richard-llvm@metafoo.co.uk> | 2013-01-29 10:02:16 +0000 |
commit | 810ad3eb447e663984a79553e3c756a04ae7c418 (patch) | |
tree | 9dc1e5bde026df9bc3da7c84f451169fe49e1603 /clang/lib/Sema/SemaDeclAttr.cpp | |
parent | 6a217e1815a8f88506d1d4a2bf3a941014b84193 (diff) | |
download | bcm5719-llvm-810ad3eb447e663984a79553e3c756a04ae7c418.tar.gz bcm5719-llvm-810ad3eb447e663984a79553e3c756a04ae7c418.zip |
Downgrade 'attribute ignored when parsing type' from error to warning, to match
the diagnostic's warn_ name. Switch some places (notably C++11 attributes)
which really wanted an error over to a different diagnostic. Finally, suppress
the diagnostic entirely for __ptr32, __ptr64 and __w64, to avoid producing
diagnostics in important system headers.
llvm-svn: 173788
Diffstat (limited to 'clang/lib/Sema/SemaDeclAttr.cpp')
-rw-r--r-- | clang/lib/Sema/SemaDeclAttr.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/lib/Sema/SemaDeclAttr.cpp b/clang/lib/Sema/SemaDeclAttr.cpp index 01a3505cf7c..cb6e898020c 100644 --- a/clang/lib/Sema/SemaDeclAttr.cpp +++ b/clang/lib/Sema/SemaDeclAttr.cpp @@ -4851,7 +4851,7 @@ bool Sema::ProcessAccessDeclAttributeList(AccessSpecDecl *ASDecl, static void checkUnusedDeclAttributes(Sema &S, const AttributeList *A) { for ( ; A; A = A->getNext()) { // Only warn if the attribute is an unignored, non-type attribute. - if (A->isUsedAsTypeAttr()) continue; + if (A->isUsedAsTypeAttr() || A->isInvalid()) continue; if (A->getKind() == AttributeList::IgnoredAttribute) continue; if (A->getKind() == AttributeList::UnknownAttribute) { |