diff options
author | Jim Ingham <jingham@apple.com> | 2014-07-08 01:07:32 +0000 |
---|---|---|
committer | Jim Ingham <jingham@apple.com> | 2014-07-08 01:07:32 +0000 |
commit | 30fadafefe67e531c809496c0f4e40593f6964db (patch) | |
tree | ff00cddd2a8dabab018500c17fbeb45fb9eb745f /lldb/source/Target/Thread.cpp | |
parent | c94285a1a02f8432f74d6c63ab7357a96497f177 (diff) | |
download | bcm5719-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.cpp | 18 |
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) { |