summaryrefslogtreecommitdiffstats
path: root/lldb/source/Commands/CommandObjectLog.cpp
diff options
context:
space:
mode:
authorPavel Labath <labath@google.com>2017-03-01 10:08:40 +0000
committerPavel Labath <labath@google.com>2017-03-01 10:08:40 +0000
commit5e336903bee9f21420c5b03d9c5552afd14376b9 (patch)
treefa2a1aa44d05503af31ef35a747a4b6a40cd54ad /lldb/source/Commands/CommandObjectLog.cpp
parent9c761a36b9a93bff188109502231cc60b96894e1 (diff)
downloadbcm5719-llvm-5e336903bee9f21420c5b03d9c5552afd14376b9.tar.gz
bcm5719-llvm-5e336903bee9f21420c5b03d9c5552afd14376b9.zip
Modernize Enable/DisableLogChannel interface a bit
Summary: Use StringRef and ArrayRef where possible. This adds an accessor to the Args class to get a view of the arguments as ArrayRef<const char *>. Reviewers: zturner Subscribers: lldb-commits Differential Revision: https://reviews.llvm.org/D30402 llvm-svn: 296592
Diffstat (limited to 'lldb/source/Commands/CommandObjectLog.cpp')
-rw-r--r--lldb/source/Commands/CommandObjectLog.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/lldb/source/Commands/CommandObjectLog.cpp b/lldb/source/Commands/CommandObjectLog.cpp
index c10f868dea4..976096387c0 100644
--- a/lldb/source/Commands/CommandObjectLog.cpp
+++ b/lldb/source/Commands/CommandObjectLog.cpp
@@ -172,8 +172,8 @@ protected:
else
log_file[0] = '\0';
bool success = m_interpreter.GetDebugger().EnableLog(
- channel.c_str(), args.GetConstArgumentVector(), log_file,
- m_options.log_options, result.GetErrorStream());
+ channel, args.GetArgumentArrayRef(), log_file, m_options.log_options,
+ result.GetErrorStream());
if (success)
result.SetStatus(eReturnStatusSuccessFinishNoResult);
else
@@ -233,7 +233,7 @@ protected:
Log::DisableAllLogChannels(&result.GetErrorStream());
result.SetStatus(eReturnStatusSuccessFinishNoResult);
} else {
- if (Log::DisableLogChannel(channel, args.GetConstArgumentVector(),
+ if (Log::DisableLogChannel(channel, args.GetArgumentArrayRef(),
result.GetErrorStream()))
result.SetStatus(eReturnStatusSuccessFinishNoResult);
}
OpenPOWER on IntegriCloud