From d13b8b55caaaf968b735bf82e49047d45e73c50b Mon Sep 17 00:00:00 2001 From: Chris Lattner Date: Mon, 23 Feb 2009 22:00:08 +0000 Subject: fix rdar://6611778, a redefinition of an interface was causing an assertion when the ivars and method list was reset into the existing interface. To fix this, mark decls as invalid when they are redefined, and don't insert ivars/methods into invalid decls. llvm-svn: 65340 --- clang/test/Sema/nested-redef.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'clang/test/Sema/nested-redef.c') diff --git a/clang/test/Sema/nested-redef.c b/clang/test/Sema/nested-redef.c index 83cd4209675..b0b12805e68 100644 --- a/clang/test/Sema/nested-redef.c +++ b/clang/test/Sema/nested-redef.c @@ -1,6 +1,7 @@ // RUN: clang -fsyntax-only -verify %s struct X { // expected-note{{previous definition is here}} - struct X { } x; // expected-error{{nested redefinition of 'X'}} + struct X { } x; // expected-error{{nested redefinition of 'X'}} \ + expected-error {{field has incomplete type}} }; struct Y { }; -- cgit v1.2.3