blob: fa8487ac66b9a6965719dff8dc91f3619b183269 [file] [log] [blame]
Daniel Dunbar4fcfde42009-11-08 01:45:36 +00001// RUN: clang-cc -triple x86_64-apple-darwin -std=c++0x -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 -std=c++0x -S %s -o %t-32.s
4// RUN: FileCheck -check-prefix LP32 --input-file=%t-32.s %s
Fariborz Jahanian249cead2009-10-01 20:39:51 +00005
6struct A {
7 A(int);
8};
9
10struct B {
11 B(A);
12};
13
14int main () {
15 (B)10;
16 B(10);
17 static_cast<B>(10);
18}
19
20// CHECK-LP64: call __ZN1AC1Ei
21// CHECK-LP64: call __ZN1BC1E1A
22// CHECK-LP64: call __ZN1AC1Ei
23// CHECK-LP64: call __ZN1BC1E1A
24// CHECK-LP64: call __ZN1AC1Ei
25// CHECK-LP64: call __ZN1BC1E1A
26
27// CHECK-LP32: call L__ZN1AC1Ei
28// CHECK-LP32: call L__ZN1BC1E1A
29// CHECK-LP32: call L__ZN1AC1Ei
30// CHECK-LP32: call L__ZN1BC1E1A
31// CHECK-LP32: call L__ZN1AC1Ei
32// CHECK-LP32: call L__ZN1BC1E1A