aboutsummaryrefslogtreecommitdiff
path: root/lib/Sema/SemaDeclAttr.cpp
diff options
context:
space:
mode:
authorChandler Carruth <chandlerc@gmail.com>2010-07-08 09:42:26 +0000
committerChandler Carruth <chandlerc@gmail.com>2010-07-08 09:42:26 +0000
commit7d5c45ed9dc2842ce8e65ea26ced0957be36a569 (patch)
tree49bc3f8620f4f74278891ae31696ebd602b77169 /lib/Sema/SemaDeclAttr.cpp
parentc63cadaeb7db6124b7c19df46d54d8693b7257b1 (diff)
Add support for differentiating between attributes ignored when handled and
unknown attributes that we discard. Add a diagnostic group for unknown attribute warnings to allow turning these off when we don't care. Also consolidates the tests for this case. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@107864 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema/SemaDeclAttr.cpp')
-rw-r--r--lib/Sema/SemaDeclAttr.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/Sema/SemaDeclAttr.cpp b/lib/Sema/SemaDeclAttr.cpp
index b7e275a9d4..3b82f58be4 100644
--- a/lib/Sema/SemaDeclAttr.cpp
+++ b/lib/Sema/SemaDeclAttr.cpp
@@ -2069,7 +2069,8 @@ static void ProcessDeclAttribute(Scope *scope, Decl *D,
// Ask target about the attribute.
const TargetAttributesSema &TargetAttrs = S.getTargetAttributesSema();
if (!TargetAttrs.ProcessDeclAttribute(scope, D, Attr, S))
- S.Diag(Attr.getLoc(), diag::warn_attribute_ignored) << Attr.getName();
+ S.Diag(Attr.getLoc(), diag::warn_unknown_attribute_ignored)
+ << Attr.getName();
break;
}
}