Start at getting "thread return" working. Doesn't work yet.
git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@163670 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/source/API/SBThread.cpp b/source/API/SBThread.cpp
index fd69264..74df380 100644
--- a/source/API/SBThread.cpp
+++ b/source/API/SBThread.cpp
@@ -877,6 +877,29 @@
return sb_error;
}
+SBError
+SBThread::ReturnToFrame (SBFrame &frame, SBValue &return_value)
+{
+ SBError sb_error;
+
+ LogSP log(lldb_private::GetLogIfAllCategoriesSet (LIBLLDB_LOG_API));
+
+ Mutex::Locker api_locker;
+ ExecutionContext exe_ctx (m_opaque_sp.get(), api_locker);
+
+
+ if (log)
+ log->Printf ("SBThread(%p)::ReturnToFrame (frame=%d)", exe_ctx.GetThreadPtr(), frame.GetFrameID());
+
+ if (exe_ctx.HasThreadScope())
+ {
+ Thread *thread = exe_ctx.GetThreadPtr();
+ sb_error.SetError (thread->ReturnToFrame(frame.GetFrameSP(), return_value.GetSP()));
+ }
+
+ return sb_error;
+}
+
bool
SBThread::Suspend()