summaryrefslogtreecommitdiffstats
path: root/debuginfo-tests/tests/ctor.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'debuginfo-tests/tests/ctor.cpp')
-rw-r--r--debuginfo-tests/tests/ctor.cpp25
1 files changed, 25 insertions, 0 deletions
diff --git a/debuginfo-tests/tests/ctor.cpp b/debuginfo-tests/tests/ctor.cpp
new file mode 100644
index 00000000000..364401a2d5c
--- /dev/null
+++ b/debuginfo-tests/tests/ctor.cpp
@@ -0,0 +1,25 @@
+// RUN: %clangxx %target_itanium_abi_host_triple -O0 -g %s -c -o %t.o
+// RUN: %clangxx %target_itanium_abi_host_triple %t.o -o %t.out
+// RUN: %test_debuginfo %s %t.out
+
+
+// DEBUGGER: break 14
+// DEBUGGER: r
+// DEBUGGER: p *this
+// CHECK-NEXT-NOT: Cannot access memory at address
+
+class A {
+public:
+ A() : zero(0), data(42)
+ {
+ }
+private:
+ int zero;
+ int data;
+};
+
+int main() {
+ A a;
+ return 0;
+}
+
OpenPOWER on IntegriCloud