1*f4a2713aSLionel Sambuc// RUN: %clang_cc1 -x objective-c++ -fms-extensions -rewrite-objc %s -o %t-rw.cpp 2*f4a2713aSLionel Sambuc// RUN: %clang_cc1 -fsyntax-only -Wno-address-of-temporary -D"id=void*" -D"SEL=void*" -D"__declspec(X)=" %t-rw.cpp 3*f4a2713aSLionel Sambuc// rdar://10803676 4*f4a2713aSLionel Sambuc 5*f4a2713aSLionel Sambucextern "C" void *sel_registerName(const char *); 6*f4a2713aSLionel Sambuc@class NSString; 7*f4a2713aSLionel Sambuc 8*f4a2713aSLionel Sambuc@interface NSNumber 9*f4a2713aSLionel Sambuc+ (NSNumber *)numberWithChar:(char)value; 10*f4a2713aSLionel Sambuc+ (NSNumber *)numberWithInt:(int)value; 11*f4a2713aSLionel Sambuc@end 12*f4a2713aSLionel Sambuc 13*f4a2713aSLionel Sambuctypedef unsigned long NSUInteger; 14*f4a2713aSLionel Sambuc 15*f4a2713aSLionel Sambuc@interface NSArray 16*f4a2713aSLionel Sambuc+ (id)arrayWithObjects:(const id [])objects count:(NSUInteger)cnt; 17*f4a2713aSLionel Sambuc@end 18*f4a2713aSLionel Sambuc 19*f4a2713aSLionel Sambucint i; 20*f4a2713aSLionel Sambucint main() { 21*f4a2713aSLionel Sambuc NSArray *array = @[ @"Hello", @1234 ]; 22*f4a2713aSLionel Sambuc if (i) { 23*f4a2713aSLionel Sambuc NSArray *array = @[ @"Hello", @1234 ]; 24*f4a2713aSLionel Sambuc } 25*f4a2713aSLionel Sambuc NSArray *array1 = @[ @"Hello", @1234, @[ @"Hello", @1234 ] ]; 26*f4a2713aSLionel Sambuc} 27*f4a2713aSLionel Sambuc 28