brintos

brintos / llvm-project-archived public Read only

0
0
Text · 988 B · 679d6e4 Raw
54 lines · plain
1# UNSUPPORTED: system-windows2 3# Test the plugin.cplusplus.display.function-name-format setting4# when interoperating multiple languages.5 6# RUN: split-file %s %t7# RUN: %clang_host -x c -c -g %t/lib.c -o %t.clib.o8# RUN: %clangxx_host -c -g %t/lib.cpp -o %t.cxxlib.o9# RUN: %clang_host %t/main.m %t.cxxlib.o %t.clib.o -o %t.out10# RUN: %lldb -x -b -s %t/commands.input %t.out -o exit 2>&1 | FileCheck %s11 12#--- lib.c13 14void foo();15 16void func() {17  foo();18}19 20#--- lib.cpp21 22namespace ns {23struct Foo {24    void method() {}25};26}27 28extern "C" {29void foo() {30  ns::Foo{}.method();31}32}33 34#--- main.m35 36void func();37 38int main() {39  func();40}41 42#--- commands.input43settings set plugin.cplusplus.display.function-name-format "this affects C++ only"44settings set -f frame-format "custom-frame '${function.name-with-args}'\n"45break set -n method46 47run48bt49 50# CHECK: custom-frame 'this affects C++ only'51# CHECK: custom-frame 'this affects C++ only'52# CHECK: custom-frame 'func'53# CHECK: custom-frame 'main'54