| 1 |
// Show that llvm-cxxfilt --quote adds quotes around demangled symbols, unless |
| 2 |
// the symbol is already quoted. |
| 3 |
|
| 4 |
RUN: split-file %s %t |
| 5 |
|
| 6 |
RUN: llvm-cxxfilt --quote < %t/symbols-in-file.test | FileCheck --match-full-lines --check-prefix=CHECK-FILE %s |
| 7 |
CHECK-FILE: "bar()" "bar()" |
| 8 |
CHECK-FILE-NEXT: "bar()" "bar()" |
| 9 |
CHECK-FILE: log() |
| 10 |
CHECK-FILE: "import thunk for std::future<void>" |
| 11 |
|
| 12 |
// Check it works with CLI symbols too. Since a quoted mangled name is not a |
| 13 |
// mangled name, it should be unchanged. |
| 14 |
RUN: llvm-cxxfilt --quote _Z3firv '"_Z3barv"' 'saw()' | FileCheck --match-full-lines --check-prefix=CHECK-CLI %s |
| 15 |
CHECK-CLI: "fir()" |
| 16 |
CHECK-CLI-NEXT: "_Z3barv" |
| 17 |
CHECK-CLI-NEXT: saw() |
| 18 |
|
| 19 |
//--- symbols-in-file.test |
| 20 |
_Z3barv "_Z3barv" |
| 21 |
"_Z3barv" _Z3barv |
| 22 |
// This is not mangled, thus it should not be quoted. |
| 23 |
log() |
| 24 |
// Check that an "import thunk for" prefix can be quoted along the demangled |
| 25 |
// name. |
| 26 |
__imp__ZSt6futureIvE |