summaryrefslogtreecommitdiffstats
path: root/clang/test
diff options
context:
space:
mode:
Diffstat (limited to 'clang/test')
-rw-r--r--clang/test/Index/rdar-8288645-invalid-code.mm1
-rw-r--r--clang/test/SemaObjC/comptypes-10.m18
2 files changed, 18 insertions, 1 deletions
diff --git a/clang/test/Index/rdar-8288645-invalid-code.mm b/clang/test/Index/rdar-8288645-invalid-code.mm
index 74e2365edcf..ec4564130a5 100644
--- a/clang/test/Index/rdar-8288645-invalid-code.mm
+++ b/clang/test/Index/rdar-8288645-invalid-code.mm
@@ -5,4 +5,3 @@
extern "C" { @implementation Foo - (id)initWithBar:(Baz<WozBar>)pepper {
// CHECK: warning: cannot find interface declaration for 'Foo'
-// CHECK: error: '@end' is missing in implementation context
diff --git a/clang/test/SemaObjC/comptypes-10.m b/clang/test/SemaObjC/comptypes-10.m
index 0a2219099fb..1a6533a600e 100644
--- a/clang/test/SemaObjC/comptypes-10.m
+++ b/clang/test/SemaObjC/comptypes-10.m
@@ -32,3 +32,21 @@ void test(id <NSCopying, NSPROTO, NSPROTO2> bar)
{
NSObject <NSCopying> *Init = bar; // expected-warning {{initializing 'NSObject<NSCopying> *' with an expression of incompatible type 'id<NSCopying,NSPROTO,NSPROTO2>'}}
}
+
+// rdar://8843851
+@interface NSObject (CAT)
++ (struct S*)Meth : (struct S*)arg;
+@end
+
+struct S {
+ char *types;
+};
+
+@interface I
+@end
+
+@implementation I
+- (struct S *)Meth : (struct S*)a {
+ return [NSObject Meth : a];
+}
+@end
OpenPOWER on IntegriCloud