aboutsummaryrefslogtreecommitdiff
path: root/lldb/source/Commands/CommandObjectThread.cpp
diff options
context:
space:
mode:
authorJonas Devlieghere <jonas@devlieghere.com>2019-04-27 06:19:42 +0000
committerJonas Devlieghere <jonas@devlieghere.com>2019-04-27 06:19:42 +0000
commit57179860a0547afc482171ef304976c7761a3fd8 (patch)
treed62c85bdab803d12e4f0bc7310a441fe70db01e1 /lldb/source/Commands/CommandObjectThread.cpp
parent40dfc3920e022beb920b7236bfdcce0e037d8e0e (diff)
downloadllvm-57179860a0547afc482171ef304976c7761a3fd8.zip
llvm-57179860a0547afc482171ef304976c7761a3fd8.tar.gz
llvm-57179860a0547afc482171ef304976c7761a3fd8.tar.bz2
[CommandObject] Use GetDebugger() helper method (NFC)
In r359354 a GetDebugger() method was added to the CommandObject class, so that we didn't have to go through the command interpreter to obtain the script interpreter. This patch simplifies other call sites where m_interpreter.GetDebugger() was used, and replaces them with a shorter call to the new method. llvm-svn: 359373
Diffstat (limited to 'lldb/source/Commands/CommandObjectThread.cpp')
-rw-r--r--lldb/source/Commands/CommandObjectThread.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/lldb/source/Commands/CommandObjectThread.cpp b/lldb/source/Commands/CommandObjectThread.cpp
index e41733f..00f52d5 100644
--- a/lldb/source/Commands/CommandObjectThread.cpp
+++ b/lldb/source/Commands/CommandObjectThread.cpp
@@ -836,7 +836,7 @@ public:
bool DoExecute(Args &command, CommandReturnObject &result) override {
bool synchronous_execution = m_interpreter.GetSynchronous();
- if (!m_interpreter.GetDebugger().GetSelectedTarget()) {
+ if (!GetDebugger().GetSelectedTarget()) {
result.AppendError("invalid target, create a debug target using the "
"'target create' command");
result.SetStatus(eReturnStatusFailed);
@@ -1116,7 +1116,7 @@ protected:
bool DoExecute(Args &command, CommandReturnObject &result) override {
bool synchronous_execution = m_interpreter.GetSynchronous();
- Target *target = m_interpreter.GetDebugger().GetSelectedTarget().get();
+ Target *target = GetDebugger().GetSelectedTarget().get();
if (target == nullptr) {
result.AppendError("invalid target, create a debug target using the "
"'target create' command");