summaryrefslogtreecommitdiffstats
path: root/clang/lib/Sema/SemaDeclAttr.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'clang/lib/Sema/SemaDeclAttr.cpp')
-rw-r--r--clang/lib/Sema/SemaDeclAttr.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/clang/lib/Sema/SemaDeclAttr.cpp b/clang/lib/Sema/SemaDeclAttr.cpp
index 4d0c6771e98..6f884435d93 100644
--- a/clang/lib/Sema/SemaDeclAttr.cpp
+++ b/clang/lib/Sema/SemaDeclAttr.cpp
@@ -57,7 +57,8 @@ enum AttributeDeclKind {
ExpectedObjectiveCInterface,
ExpectedMethodOrProperty,
ExpectedStructOrUnion,
- ExpectedStructOrUnionOrClass
+ ExpectedStructOrUnionOrClass,
+ ExpectedType
};
//===----------------------------------------------------------------------===//
@@ -1249,7 +1250,8 @@ static void handleExtVectorTypeAttr(Sema &S, Scope *scope, Decl *D,
if (TD == 0) {
// __attribute__((ext_vector_type(N))) can only be applied to typedefs
// and type-ids.
- S.Diag(Attr.getLoc(), diag::err_typecheck_ext_vector_not_typedef);
+ S.Diag(Attr.getLoc(), diag::err_attribute_wrong_decl_type) <<
+ Attr.getName() << ExpectedType;
return;
}
OpenPOWER on IntegriCloud