Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 0 additions & 3 deletions lldb/include/lldb/API/SBThread.h
Original file line number Diff line number Diff line change
Expand Up @@ -251,9 +251,6 @@ class LLDB_API SBThread {

void SetThread(const lldb::ThreadSP &lldb_object_sp);

SBError ResumeNewPlan(lldb_private::ExecutionContext &exe_ctx,
lldb_private::ThreadPlan *new_plan);

lldb::ThreadSP GetSP() const;

lldb::ExecutionContextRefSP m_opaque_sp;
Expand Down
24 changes: 7 additions & 17 deletions lldb/source/API/SBThread.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -495,21 +495,14 @@ bool SBThread::GetInfoItemByPathAsString(const char *path, SBStream &strm) {
return success;
}

SBError SBThread::ResumeNewPlan(ExecutionContext &exe_ctx,
ThreadPlan *new_plan) {
SBError sb_error;

static Status ResumeNewPlan(ExecutionContext &exe_ctx, ThreadPlan *new_plan) {
Process *process = exe_ctx.GetProcessPtr();
if (!process) {
sb_error = Status::FromErrorString("No process in SBThread::ResumeNewPlan");
return sb_error;
}
if (!process)
return Status::FromErrorString("No process in SBThread::ResumeNewPlan");

Thread *thread = exe_ctx.GetThreadPtr();
if (!thread) {
sb_error = Status::FromErrorString("No thread in SBThread::ResumeNewPlan");
return sb_error;
}
if (!thread)
return Status::FromErrorString("No thread in SBThread::ResumeNewPlan");

// User level plans should be Controlling Plans so they can be interrupted,
// other plans executed, and then a "continue" will resume the plan.
Expand All @@ -522,11 +515,8 @@ SBError SBThread::ResumeNewPlan(ExecutionContext &exe_ctx,
process->GetThreadList().SetSelectedThreadByID(thread->GetID());

if (process->GetTarget().GetDebugger().GetAsyncExecution())
sb_error.ref() = process->Resume();
else
sb_error.ref() = process->ResumeSynchronous(nullptr);

return sb_error;
return process->Resume();
return process->ResumeSynchronous(nullptr);
}

void SBThread::StepOver(lldb::RunMode stop_other_threads) {
Expand Down
Loading