summaryrefslogtreecommitdiffstats
path: root/lldb/source/Target/Thread.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/source/Target/Thread.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/source/Target/Thread.cpp')
-rw-r--r--lldb/source/Target/Thread.cpp18
1 files changed, 17 insertions, 1 deletions
diff --git a/lldb/source/Target/Thread.cpp b/lldb/source/Target/Thread.cpp
index 89d4359ca6f..3aa7fbcaad9 100644
--- a/lldb/source/Target/Thread.cpp
+++ b/lldb/source/Target/Thread.cpp
@@ -420,7 +420,7 @@ Thread::GetStopInfo ()
const uint32_t stop_id = process_sp ? process_sp->GetStopID() : UINT32_MAX;
if (plan_sp && plan_sp->PlanSucceeded())
{
- return StopInfo::CreateStopReasonWithPlan (plan_sp, GetReturnValueObject());
+ return StopInfo::CreateStopReasonWithPlan (plan_sp, GetReturnValueObject(), GetExpressionVariable());
}
else
{
@@ -1184,6 +1184,22 @@ Thread::GetReturnValueObject ()
return ValueObjectSP();
}
+ClangExpressionVariableSP
+Thread::GetExpressionVariable ()
+{
+ if (!m_completed_plan_stack.empty())
+ {
+ for (int i = m_completed_plan_stack.size() - 1; i >= 0; i--)
+ {
+ ClangExpressionVariableSP expression_variable_sp;
+ expression_variable_sp = m_completed_plan_stack[i]->GetExpressionVariable();
+ if (expression_variable_sp)
+ return expression_variable_sp;
+ }
+ }
+ return ClangExpressionVariableSP();
+}
+
bool
Thread::IsThreadPlanDone (ThreadPlan *plan)
{
OpenPOWER on IntegriCloud