summaryrefslogtreecommitdiffstats
path: root/test/SemaObjC
diff options
context:
space:
mode:
authored <ed@FreeBSD.org>2009-06-03 13:29:08 +0000
committered <ed@FreeBSD.org>2009-06-03 13:29:08 +0000
commit48ecc7affef226b2bac1e08bdfdc059306a1734c (patch)
tree4075b1f9165f6c8d2b9a7e98b89a1348669f78fe /test/SemaObjC
parentf27e5a09a0d815b8a4814152954ff87dadfdefc0 (diff)
downloadFreeBSD-src-48ecc7affef226b2bac1e08bdfdc059306a1734c.zip
FreeBSD-src-48ecc7affef226b2bac1e08bdfdc059306a1734c.tar.gz
Import Clang, at r72770.
Diffstat (limited to 'test/SemaObjC')
-rw-r--r--test/SemaObjC/objc2-merge-gc-attribue-decl.m18
1 files changed, 18 insertions, 0 deletions
diff --git a/test/SemaObjC/objc2-merge-gc-attribue-decl.m b/test/SemaObjC/objc2-merge-gc-attribue-decl.m
index 4e3b3ec..9dae1ef 100644
--- a/test/SemaObjC/objc2-merge-gc-attribue-decl.m
+++ b/test/SemaObjC/objc2-merge-gc-attribue-decl.m
@@ -10,3 +10,21 @@ extern id p1;
extern id CFRunLoopGetMain();
extern __strong id CFRunLoopGetMain();
+extern __weak id WLoopGetMain(); // expected-note {{previous declaration is here}}
+extern id WLoopGetMain(); // expected-error {{conflicting types for 'WLoopGetMain'}}
+
+extern id p3; // expected-note {{previous definition is here}}
+extern __weak id p3; // expected-error {{redefinition of 'p3' with a different type}}
+
+extern void *p4; // expected-note {{previous definition is here}}
+extern void * __strong p4; // expected-error {{redefinition of 'p4' with a different type}}
+
+extern id p5;
+extern __strong id p5;
+
+extern char* __strong p6; // expected-note {{previous definition is here}}
+extern char* p6; // expected-error {{redefinition of 'p6' with a different type}}
+
+// FIXME. We do not issue error here because we don't put the attribute on the pointer type.
+extern __strong char* p7;
+extern char* p7;
OpenPOWER on IntegriCloud