summaryrefslogtreecommitdiff
path: root/clang/test/SemaObjC/ivar-sem-check-1.m
diff options
context:
space:
mode:
Diffstat (limited to 'clang/test/SemaObjC/ivar-sem-check-1.m')
-rw-r--r--clang/test/SemaObjC/ivar-sem-check-1.m19
1 files changed, 19 insertions, 0 deletions
diff --git a/clang/test/SemaObjC/ivar-sem-check-1.m b/clang/test/SemaObjC/ivar-sem-check-1.m
new file mode 100644
index 0000000..de038f5
--- /dev/null
+++ b/clang/test/SemaObjC/ivar-sem-check-1.m
@@ -0,0 +1,19 @@
+// RUN: %clang_cc1 -fsyntax-only -verify %s
+
+struct S; // expected-note{{forward declaration of 'struct S'}}
+typedef int FOO();
+
+@interface INTF
+{
+ struct F {} JJ;
+ int arr[]; // expected-error {{field has incomplete type}}
+ struct S IC; // expected-error {{field has incomplete type}}
+ struct T { // expected-note {{previous definition is here}}
+ struct T {} X; // expected-error {{nested redefinition of 'T'}}
+ }YYY;
+ FOO BADFUNC; // expected-error {{field 'BADFUNC' declared as a function}}
+ int kaka; // expected-note {{previous declaration is here}}
+ int kaka; // expected-error {{duplicate member 'kaka'}}
+ char ch[]; // expected-error {{field has incomplete type}}
+}
+@end