71 lines · plain
1// RUN: %clang_cc1 -x objective-c++ -Wno-return-type -fblocks -fms-extensions -rewrite-objc %s -o %t-rw.cpp2// RUN: %clang_cc1 -fsyntax-only -std=gnu++98 -fblocks -Wno-address-of-temporary -D"Class=void*" -D"id=void*" -D"SEL=void*" -D"__declspec(X)=" %t-rw.cpp3 4@protocol PROTO @end5 6@interface empty_root @end7 8@interface root_with_ivars9{10 id ROOT_IVAR;11 id ROOT1_IVAR;12}13@end14 15@interface MAXIMAL : root_with_ivars<PROTO>16{17 double D_IVAR;18 double D_PROPERTY;19}20- (void) V_METH;21@end22 23@implementation MAXIMAL24- (void) V_METH {}25@end26//=========================================27@interface empty_class @end28 29@implementation empty_class @end30//=========================================31@interface class_empty_root : empty_root @end32 33@implementation class_empty_root @end34//=========================================35@interface class_with_ivars : empty_root36{37 int class_with_ivars_IVAR;38}39@end40 41@implementation class_with_ivars @end42//=========================================43@interface class_has_no_ivar : root_with_ivars @end44 45@implementation class_has_no_ivar @end46 47//===================== class needs to be synthesized here =====================48@interface SUPER {49@public50 double divar;51 SUPER *p_super;52}53@end54 55@interface INTF @end56 57@implementation INTF 58- (SUPER *) Meth : (SUPER *)arg { 59 return arg->p_super; 60}61@end62 63@class FORM_CLASS;64@interface INTF_DECL {65}66@end67 68double Meth(INTF_DECL *p, FORM_CLASS *f) {69 return 1.34;70}71