diff options
author | Douglas Gregor <dgregor@apple.com> | 2009-01-19 19:26:10 +0000 |
---|---|---|
committer | Douglas Gregor <dgregor@apple.com> | 2009-01-19 19:26:10 +0000 |
commit | dd430f7ec9511f440a55d090c1a8d4df118e0e68 (patch) | |
tree | 7b670938f8911ad43483817101a0f90454211517 /clang/test/SemaObjC | |
parent | ababe7d47df60f0a68b3a3712de4032e1a12d3fb (diff) | |
download | bcm5719-llvm-dd430f7ec9511f440a55d090c1a8d4df118e0e68.tar.gz bcm5719-llvm-dd430f7ec9511f440a55d090c1a8d4df118e0e68.zip |
Centralize error reporting of improper uses of incomplete types in the
new DiagnoseIncompleteType. It provides additional information about
struct/class/union/enum types when possible, either by pointing to the
forward declaration of that type or by pointing to the definition (if
we're in the process of defining that type).
Fixes <rdar://problem/6500531>.
llvm-svn: 62521
Diffstat (limited to 'clang/test/SemaObjC')
-rw-r--r-- | clang/test/SemaObjC/ivar-sem-check-1.m | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/clang/test/SemaObjC/ivar-sem-check-1.m b/clang/test/SemaObjC/ivar-sem-check-1.m index a6d1a22a915..1ec4e57ce84 100644 --- a/clang/test/SemaObjC/ivar-sem-check-1.m +++ b/clang/test/SemaObjC/ivar-sem-check-1.m @@ -1,19 +1,19 @@ // RUN: clang -fsyntax-only -verify %s -struct S; +struct S; // expected-note{{forward declaration of 'struct S'}} typedef int FOO(); @interface INTF { struct F {} JJ; - int arr[]; // expected-error {{field 'arr' has incomplete type}} - struct S IC; // expected-error {{field 'IC' has incomplete type}} + 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 'ch' has incomplete type}} + char ch[]; // expected-error {{field has incomplete type}} } @end |