1*67e74705SXin Li// RUN: %clang_cc1 -fsyntax-only -verify -Wno-objc-root-class %s 2*67e74705SXin Li 3*67e74705SXin Litypedef int INTF3; // expected-note {{previous definition is here}} 4*67e74705SXin Li 5*67e74705SXin Li@interface SUPER @end // expected-note {{previous definition is here}} 6*67e74705SXin Li 7*67e74705SXin Li@interface OBJECT @end 8*67e74705SXin Li 9*67e74705SXin Li@interface INTF : OBJECT 10*67e74705SXin Li@end 11*67e74705SXin Li 12*67e74705SXin Li@implementation INTF @end // expected-note {{previous definition is here}} 13*67e74705SXin Li 14*67e74705SXin Li@implementation INTF // expected-error {{reimplementation of class 'INTF'}} 15*67e74705SXin Li@end 16*67e74705SXin Li 17*67e74705SXin Li 18*67e74705SXin Li@interface INTF1 : OBJECT 19*67e74705SXin Li@end 20*67e74705SXin Li 21*67e74705SXin Li@implementation INTF1 : SUPER // expected-error {{conflicting super class name 'SUPER'}} 22*67e74705SXin Li@end 23*67e74705SXin Li 24*67e74705SXin Li@interface INTF2 25*67e74705SXin Li@end 26*67e74705SXin Li 27*67e74705SXin Li@implementation INTF2 : SUPR // expected-error {{cannot find interface declaration for 'SUPR', superclass of 'INTF2'}} 28*67e74705SXin Li@end 29*67e74705SXin Li 30*67e74705SXin Li@implementation INTF3 @end // expected-error {{redefinition of 'INTF3' as different kind of symbol}} 31*67e74705SXin Li 32*67e74705SXin Li@implementation INTF4 @end // expected-warning {{cannot find interface declaration for 'INTF4'}} 33*67e74705SXin Li 34*67e74705SXin Li@class INTF5; // expected-note{{forward declaration of class here}} 35*67e74705SXin Li 36*67e74705SXin Li@implementation INTF5 { // expected-warning {{cannot find interface declaration for 'INTF5'}} 37*67e74705SXin Li int x; 38*67e74705SXin Li} 39*67e74705SXin Li@end 40*67e74705SXin Li 41