1*f4a2713aSLionel Sambuc// RUN: %clang_cc1 -x objective-c++ -fblocks -fms-extensions -rewrite-objc -fobjc-runtime=macosx-fragile-10.5 %s -o %t-rw.cpp 2*f4a2713aSLionel Sambuc// RUN: %clang_cc1 -fsyntax-only -Wno-address-of-temporary -D"SEL=void*" -D"__declspec(X)=" %t-rw.cpp 3*f4a2713aSLionel Sambuc// RUN: %clang_cc1 -x objective-c++ -fblocks -fms-extensions -rewrite-objc %s -o %t-modern-rw.cpp 4*f4a2713aSLionel Sambuc// RUN: %clang_cc1 -fsyntax-only -Wno-address-of-temporary -D"SEL=void*" -D"__declspec(X)=" %t-modern-rw.cpp 5*f4a2713aSLionel Sambuc// radar 7630551 6*f4a2713aSLionel Sambuc 7*f4a2713aSLionel Sambuctypedef unsigned long size_t; 8*f4a2713aSLionel Sambucvoid f(void (^b)(char c)); 9*f4a2713aSLionel Sambuc 10*f4a2713aSLionel Sambuc@interface a 11*f4a2713aSLionel Sambuc- (void)processStuff; 12*f4a2713aSLionel Sambuc@end 13*f4a2713aSLionel Sambuc 14*f4a2713aSLionel Sambuc@implementation a 15*f4a2713aSLionel Sambuc- (void)processStuff { 16*f4a2713aSLionel Sambuc f(^(char x) { }); 17*f4a2713aSLionel Sambuc} 18*f4a2713aSLionel Sambuc@end 19*f4a2713aSLionel Sambuc 20*f4a2713aSLionel Sambuc@interface b 21*f4a2713aSLionel Sambuc- (void)processStuff; 22*f4a2713aSLionel Sambuc@end 23*f4a2713aSLionel Sambuc 24*f4a2713aSLionel Sambuc@implementation b 25*f4a2713aSLionel Sambuc- (void)processStuff { 26*f4a2713aSLionel Sambuc f(^(char x) { }); 27*f4a2713aSLionel Sambuc} 28*f4a2713aSLionel Sambuc@end 29