[lldb][NFC] Check in completion crash test case
authorRaphael Isemann <teemperor@gmail.com>
Wed, 31 Jul 2019 12:15:21 +0000 (12:15 +0000)
committerRaphael Isemann <teemperor@gmail.com>
Wed, 31 Jul 2019 12:15:21 +0000 (12:15 +0000)
llvm-svn: 367420

lldb/packages/Python/lldbsuite/test/expression_command/completion-crash-incomplete-record/Makefile [new file with mode: 0644]
lldb/packages/Python/lldbsuite/test/expression_command/completion-crash-incomplete-record/TestCompletionCrashIncompleteRecord.py [new file with mode: 0644]
lldb/packages/Python/lldbsuite/test/expression_command/completion-crash-incomplete-record/main.cpp [new file with mode: 0644]

diff --git a/lldb/packages/Python/lldbsuite/test/expression_command/completion-crash-incomplete-record/Makefile b/lldb/packages/Python/lldbsuite/test/expression_command/completion-crash-incomplete-record/Makefile
new file mode 100644 (file)
index 0000000..82355a2
--- /dev/null
@@ -0,0 +1,3 @@
+LEVEL = ../../make
+CXX_SOURCES := main.cpp
+include $(LEVEL)/Makefile.rules
diff --git a/lldb/packages/Python/lldbsuite/test/expression_command/completion-crash-incomplete-record/TestCompletionCrashIncompleteRecord.py b/lldb/packages/Python/lldbsuite/test/expression_command/completion-crash-incomplete-record/TestCompletionCrashIncompleteRecord.py
new file mode 100644 (file)
index 0000000..68bd864
--- /dev/null
@@ -0,0 +1,4 @@
+from lldbsuite.test import lldbinline
+from lldbsuite.test import decorators
+
+lldbinline.MakeInlineTest(__file__, globals(), [decorators.skipIf(bugnumber="rdar://53756116")])
diff --git a/lldb/packages/Python/lldbsuite/test/expression_command/completion-crash-incomplete-record/main.cpp b/lldb/packages/Python/lldbsuite/test/expression_command/completion-crash-incomplete-record/main.cpp
new file mode 100644 (file)
index 0000000..f7ca83c
--- /dev/null
@@ -0,0 +1,11 @@
+int i;
+struct F {
+  int &r;
+  F() : r(i) {}
+};
+template <class T> struct unique_ptr {
+  F i;
+  unique_ptr() : i() {//%self.dbg.GetCommandInterpreter().HandleCompletion("e ", len("e "), 0, -1, lldb.SBStringList())
+}
+};
+int main() {unique_ptr<F> u; }