blob: 27d200f4635b0616e7ff7f6386b0b51d27735db9 [file] [log] [blame]
Fariborz Jahanian8f489d62009-09-23 22:34:00 +00001// RUN: clang-cc -triple x86_64-apple-darwin -S %s -o %t-64.s &&
2// RUN: FileCheck -check-prefix LP64 --input-file=%t-64.s %s &&
3// RUN: clang-cc -triple i386-apple-darwin -S %s -o %t-32.s &&
4// RUN: FileCheck -check-prefix LP32 --input-file=%t-32.s %s &&
5// RUN: true
6
7struct A {};
8
9struct B
10{
11 operator A&();
12};
13
14
15struct D : public B {
16 operator A();
17};
18
19extern B f();
20extern D d();
21
22int main() {
23 const A& rca = f();
24 const A& rca2 = d();
25}
26
27// CHECK-LP64: call __ZN1BcvR1AEv
28// CHECK-LP64: call __ZN1BcvR1AEv
29
30// CHECK-LP32: call L__ZN1BcvR1AEv
31// CHECK-LP32: call L__ZN1BcvR1AEv