Logan Chien | eae5a820 | 2012-10-10 06:56:20 +0000 | [diff] [blame] | 1 | #include "stdarg.h" |
| 2 | |
| 3 | namespace test1 { |
| 4 | void test1(const char *fmt, va_list ap) { |
| 5 | } |
| 6 | } |
| 7 | |
| 8 | class Test2 { |
| 9 | public: |
| 10 | void test2(const char *fmt, va_list ap); |
| 11 | }; |
| 12 | |
| 13 | void Test2::test2(const char *fmt, va_list ap) { |
| 14 | } |
| 15 | |
| 16 | // RUN: %clang_cc1 %s -emit-llvm -o - \ |
| 17 | // RUN: -triple armv7-unknown-linux \ |
| 18 | // RUN: | FileCheck -check-prefix=MANGLE-ARM-AAPCS %s |
| 19 | // CHECK-MANGLE-ARM-AAPCS: @_ZN5test15test1EPKcSt9__va_list |
| 20 | // CHECK-MANGLE-ARM-AAPCS: @_ZN5Test25test2EPKcSt9__va_list |
| 21 | |
| 22 | // RUN: %clang_cc1 %s -emit-llvm -o - \ |
| 23 | // RUN: -triple armv7-unknown-linux -target-abi apcs-gnu \ |
| 24 | // RUN: | FileCheck -check-prefix=MANGLE-ARM-APCS %s |
| 25 | // CHECK-MANGLE-ARM-APCS: @_ZN5test15test1EPKcPv |
| 26 | // CHECK-MANGLE-ARM-APCS: @_ZN5Test25test2EPKcPv |
| 27 | |
| 28 | // RUN: %clang_cc1 %s -emit-llvm -o - \ |
| 29 | // RUN: -triple mipsel-unknown-linux \ |
| 30 | // RUN: | FileCheck -check-prefix=MANGLE-MIPSEL %s |
| 31 | // CHECK-MANGLE-MIPSEL: @_ZN5test15test1EPKcPv |
| 32 | // CHECK-MANGLE-MIPSEL: @_ZN5Test25test2EPKcPv |
| 33 | |
| 34 | // RUN: %clang_cc1 %s -emit-llvm -o - \ |
| 35 | // RUN: -triple i686-unknown-linux \ |
| 36 | // RUN: | FileCheck -check-prefix=MANGLE-X86 %s |
| 37 | // CHECK-MANGLE-X86: @_ZN5test15test1EPKcPc |
| 38 | // CHECK-MANGLE-X86: @_ZN5Test25test2EPKcPc |
| 39 | |
| 40 | // RUN: %clang_cc1 %s -emit-llvm -o - \ |
| 41 | // RUN: -triple x86_64-unknown-linux \ |
| 42 | // RUN: | FileCheck -check-prefix=MANGLE-X86-64 %s |
| 43 | // CHECK-MANGLE-X86-64: @_ZN5test15test1EPKcP13__va_list_tag |
| 44 | // CHECK-MANGLE-X86-64: @_ZN5Test25test2EPKcP13__va_list_tag |