summaryrefslogtreecommitdiffstats
path: root/lldb/packages/Python/lldbsuite/test/commands/expression/top-level/dummy.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lldb/packages/Python/lldbsuite/test/commands/expression/top-level/dummy.cpp')
-rw-r--r--lldb/packages/Python/lldbsuite/test/commands/expression/top-level/dummy.cpp15
1 files changed, 15 insertions, 0 deletions
diff --git a/lldb/packages/Python/lldbsuite/test/commands/expression/top-level/dummy.cpp b/lldb/packages/Python/lldbsuite/test/commands/expression/top-level/dummy.cpp
new file mode 100644
index 00000000000..fa49bd4bda7
--- /dev/null
+++ b/lldb/packages/Python/lldbsuite/test/commands/expression/top-level/dummy.cpp
@@ -0,0 +1,15 @@
+#include <stdio.h>
+
+// These are needed to make sure that the linker does not strip the parts of the
+// C++ abi library that are necessary to execute the expressions in the
+// debugger. It would be great if we did not need to do this, but the fact that
+// LLDB cannot conjure up the abi library on demand is not relevant for testing
+// top level expressions.
+struct DummyA {};
+struct DummyB : public virtual DummyA {};
+
+int main() {
+ DummyB b;
+ printf("This is a dummy\n"); // Set breakpoint here
+ return 0;
+}
OpenPOWER on IntegriCloud