summaryrefslogtreecommitdiffstats
path: root/lldb/test/expression_command/call-function/main.cpp
diff options
context:
space:
mode:
authorJim Ingham <jingham@apple.com>2014-07-08 01:07:32 +0000
committerJim Ingham <jingham@apple.com>2014-07-08 01:07:32 +0000
commit30fadafefe67e531c809496c0f4e40593f6964db (patch)
treeff00cddd2a8dabab018500c17fbeb45fb9eb745f /lldb/test/expression_command/call-function/main.cpp
parentc94285a1a02f8432f74d6c63ab7357a96497f177 (diff)
downloadbcm5719-llvm-30fadafefe67e531c809496c0f4e40593f6964db.tar.gz
bcm5719-llvm-30fadafefe67e531c809496c0f4e40593f6964db.zip
If a hand-called function is interrupted by hitting a breakpoint, then
when you continue to finish off the function call, the expression result will be included as part of the thread stop info. llvm-svn: 212506
Diffstat (limited to 'lldb/test/expression_command/call-function/main.cpp')
-rw-r--r--lldb/test/expression_command/call-function/main.cpp14
1 files changed, 14 insertions, 0 deletions
diff --git a/lldb/test/expression_command/call-function/main.cpp b/lldb/test/expression_command/call-function/main.cpp
index 09c8633114b..ca43c2eabe5 100644
--- a/lldb/test/expression_command/call-function/main.cpp
+++ b/lldb/test/expression_command/call-function/main.cpp
@@ -1,11 +1,25 @@
#include <iostream>
#include <string>
+struct Five
+{
+ int number;
+ const char *name;
+};
+
+Five
+returnsFive()
+{
+ Five my_five = { 5, "five" };
+ return my_five;
+}
+
int main (int argc, char const *argv[])
{
std::string str = "Hello world";
std::cout << str << std::endl;
std::cout << str.c_str() << std::endl;
+ Five main_five = returnsFive();
#if 0
print str
print str.c_str()
OpenPOWER on IntegriCloud