summaryrefslogtreecommitdiffstats
path: root/clang/test
diff options
context:
space:
mode:
authorSteve Naroff <snaroff@apple.com>2009-02-21 19:50:43 +0000
committerSteve Naroff <snaroff@apple.com>2009-02-21 19:50:43 +0000
commitcd8d5722830c7765e98b2e78b44bb7d6932c658d (patch)
tree9f850de60ebc0e0c3992f7766c2162f3b2be6d3c /clang/test
parent0c9404e0a764fc15a7080ccabf10eeacd2265d68 (diff)
downloadbcm5719-llvm-cd8d5722830c7765e98b2e78b44bb7d6932c658d.tar.gz
bcm5719-llvm-cd8d5722830c7765e98b2e78b44bb7d6932c658d.zip
Warn about bogus protocol qualifiers.
llvm-svn: 65241
Diffstat (limited to 'clang/test')
-rw-r--r--clang/test/SemaObjC/protocol-archane.m7
1 files changed, 6 insertions, 1 deletions
diff --git a/clang/test/SemaObjC/protocol-archane.m b/clang/test/SemaObjC/protocol-archane.m
index bfae348f082..2cba1fad051 100644
--- a/clang/test/SemaObjC/protocol-archane.m
+++ b/clang/test/SemaObjC/protocol-archane.m
@@ -21,4 +21,9 @@ void foo(id x) {
// FIXME: provide a better diagnostic (no typedef).
- (void)m2:(id <MyProtocol> short)arg1; // expected-error {{'short type-name' is invalid}}
-@end \ No newline at end of file
+@end
+
+typedef int NotAnObjCObjectType;
+
+// GCC doesn't diagnose this.
+NotAnObjCObjectType <SomeProtocol> *obj; // expected-warning {{ignoring protocol qualifiers on non-ObjC type}}
OpenPOWER on IntegriCloud