llvm-capstone/debuginfo-tests/aggregate-indirect-arg.cpp
Adrian Prantl 888e023e0d Add an lldb wrapper script that implements gdb-compatible commands on top
of lldb. This will be the new default method for executing the tests in
this repository on Darwin.
There is also a related patch for llvm/utils/test_debuginfo.pl coming.

I also relaxed some of the checks to work with both gdb's and lldb's
output.

llvm-svn: 190185
2013-09-06 18:10:44 +00:00

33 lines
505 B
C++

// RUN: %clangxx -O0 -g %s -c -o %t.o
// RUN: %clangxx %t.o -o %t.out
// RUN: %test_debuginfo %s %t.out
// Radar 8945514
// DEBUGGER: break 22
// DEBUGGER: r
// DEBUGGER: p v
// CHECK: ${{[0-9]+}} = {
// CHECK-NEXT: Data = 0x0{{,|(0+$)}}
// CHECK-NEXT: Kind = 2142
class SVal {
public:
~SVal() {}
const void* Data;
unsigned Kind;
};
void bar(SVal &v) {}
class A {
public:
void foo(SVal v) { bar(v); }
};
int main() {
SVal v;
v.Data = 0;
v.Kind = 2142;
A a;
a.foo(v);
return 0;
}