| 1 |
// RUN: %clang_cc1 -E %s -triple x86_64-linux-gnu -x c++ -o - | FileCheck %s --check-prefix=NO-RELATIVE-VTABLE |
| 2 |
// RUN: %clang_cc1 -E %s -triple x86_64-linux-gnu -x c++ -fexperimental-relative-c++-abi-vtables -o - | FileCheck %s --check-prefix=RELATIVE-VTABLE |
| 3 |
// RUN: %clang_cc1 -E %s -triple x86_64-linux-gnu -x c++ -fno-experimental-relative-c++-abi-vtables -o - | FileCheck %s --check-prefix=NO-RELATIVE-VTABLE |
| 4 |
// RUN: %clang_cc1 -E %s -triple x86_64-linux-gnu -x c -fexperimental-relative-c++-abi-vtables -o - | FileCheck %s --check-prefix=NO-RELATIVE-VTABLE |
| 5 |
|
| 6 |
#if __has_feature(cxx_abi_relative_vtable) |
| 7 |
int has_relative_vtable(); |
| 8 |
#else |
| 9 |
int has_no_relative_vtable(); |
| 10 |
#endif |
| 11 |
|
| 12 |
// RELATIVE-VTABLE: has_relative_vtable |
| 13 |
// NO-RELATIVE-VTABLE: has_no_relative_vtable |