2011-10-02 09:16:38 +08:00
|
|
|
// RUN: %clang_cc1 -fobjc-gc -triple x86_64-apple-darwin10 -fobjc-fragile-abi -emit-llvm -o - %s
|
2010-06-18 07:00:29 +08:00
|
|
|
// rdar: // 7501812
|
|
|
|
|
2010-11-19 03:01:18 +08:00
|
|
|
struct A {
|
|
|
|
int member;
|
|
|
|
void foo();
|
|
|
|
A *operator->();
|
|
|
|
};
|
2010-06-18 07:00:29 +08:00
|
|
|
struct B : A { };
|
|
|
|
|
|
|
|
@interface BInt {
|
|
|
|
@private
|
|
|
|
B *b;
|
|
|
|
}
|
|
|
|
- (B)value;
|
|
|
|
- (void)setValue : (B) arg;
|
|
|
|
@property B value;
|
|
|
|
@end
|
|
|
|
|
|
|
|
void g(BInt *bint) {
|
2010-11-19 03:01:18 +08:00
|
|
|
bint.value.foo();
|
|
|
|
bint.value->member = 17;
|
|
|
|
int x = bint.value.member;
|
2010-06-18 07:00:29 +08:00
|
|
|
}
|
|
|
|
|