1 /* Redeclarations of class names. */
2 /* { dg-do compile } */
3 /* { dg-additional-options "-Wno-objc-root-class" } */
5 typedef int foo; /* { dg-line foo_def } */
7 @class foo; /* { dg-error "redeclared as different kind of symbol" } */
8 /* { dg-error "previous declaration of" "" { target *-*-* } foo_def } */
10 typedef int bar; /* { dg-line bar_def } */
12 #if defined(__has_attribute) && __has_attribute(objc_root_class)
13 __attribute__((objc_root_class))
16 @end /* { dg-error "redeclared as different kind of symbol" } */
17 /* { dg-error "previous declaration of" "" { target *-*-* } bar_def } */
19 int glob; /* { dg-line glob_def } */
22 @end /* { dg-line glob_impl_end } */
23 /* { dg-error "redeclared as different kind of symbol" "" { target *-*-* } glob_impl_end } */
24 /* { dg-error "previous declaration of" "" { target *-*-* } glob_def } */
25 /* { dg-warning "annot find interface declaration" "" { target *-*-* } glob_impl_end } */