80 lines · plain
1// RUN: %clang_cc1 -triple x86_64-apple-darwin10 -emit-llvm -o - %s | FileCheck %s2// RUN: %clang_cc1 -triple i386-apple-darwin9 -fobjc-runtime=macosx-fragile-10.5 -emit-llvm -o - %s | FileCheck %s3 4typedef struct {5#ifdef __LP64__6 unsigned char b[15];7#else8 unsigned char b[7];9#endif10} bools_minus_one;11 12typedef struct {13#ifdef __LP64__14 unsigned char b[16];15#else16 unsigned char b[8];17#endif18} bools;19 20 21@interface Foo22{23#ifndef __LP64__24 bools x;25 bools_minus_one y;26#endif27}28@property(assign) bools bools_p;29@property(assign) bools_minus_one bools_minus_one_p;30@end31 32@implementation Foo33@synthesize bools_p=x;34@synthesize bools_minus_one_p=y;35@end36 37#ifdef __LP64__38typedef __int128_t dword;39#else40typedef long long int dword;41#endif42 43@interface Test_dwords44{45#ifndef __LP64__46 dword dw;47#endif48}49@property(assign) dword dword_p;50@end51 52@implementation Test_dwords53@synthesize dword_p=dw;54@end55 56 57@interface Test_floats58{59 float fl;60 double d;61 long double ld;62}63@property(assign) float fl_p;64@property(assign) double d_p;65@property(assign) long double ld_p;66@end67 68@implementation Test_floats69@synthesize fl_p = fl;70@synthesize d_p = d;71@synthesize ld_p = ld;72@end73 74// CHECK: call void @objc_copyStruct75// CHECK: call void @objc_copyStruct76// CHECK: call void @objc_copyStruct77// CHECK: call void @objc_copyStruct78// CHECK: call void @objc_copyStruct79// CHECK: call void @objc_copyStruct80