aboutsummaryrefslogtreecommitdiff
path: root/lib/Sema/SemaType.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/Sema/SemaType.cpp')
-rw-r--r--lib/Sema/SemaType.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/Sema/SemaType.cpp b/lib/Sema/SemaType.cpp
index eafaae5d87..820a1c85f0 100644
--- a/lib/Sema/SemaType.cpp
+++ b/lib/Sema/SemaType.cpp
@@ -338,7 +338,11 @@ QualType Sema::GetTypeForDeclarator(Declarator &D, Scope *S) {
T = Context.IntTy;
D.setInvalidType(true);
}
+ } else if (T->isObjCInterfaceType()) {
+ Diag(DeclType.Loc, diag::warn_objc_array_of_interfaces,
+ T.getAsString());
}
+
// C99 6.7.5.2p1: The size expression shall have integer type.
if (ArraySize && !ArraySize->getType()->isIntegerType()) {
Diag(ArraySize->getLocStart(), diag::err_array_size_non_int,