From 47cbf4a07bdfe8f5ef56be7a0caf003f91a00a9e Mon Sep 17 00:00:00 2001 From: Pavel Labath Date: Tue, 10 Apr 2018 09:03:59 +0000 Subject: Move Args::StringTo*** functions to a new OptionArgParser class Summary: The idea behind this is to move the functionality which depend on other lldb classes into a separate class. This way, the Args class can be turned into a lightweight arc+argv wrapper and moved into the lower lldb layers. Reviewers: jingham, zturner Subscribers: lldb-commits Differential Revision: https://reviews.llvm.org/D44306 llvm-svn: 329677 --- lldb/source/Commands/CommandObjectProcess.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'lldb/source/Commands/CommandObjectProcess.cpp') diff --git a/lldb/source/Commands/CommandObjectProcess.cpp b/lldb/source/Commands/CommandObjectProcess.cpp index c763fe518855..c2f5229c6741 100644 --- a/lldb/source/Commands/CommandObjectProcess.cpp +++ b/lldb/source/Commands/CommandObjectProcess.cpp @@ -24,6 +24,7 @@ #include "lldb/Interpreter/Args.h" #include "lldb/Interpreter/CommandInterpreter.h" #include "lldb/Interpreter/CommandReturnObject.h" +#include "lldb/Interpreter/OptionArgParser.h" #include "lldb/Interpreter/Options.h" #include "lldb/Target/Platform.h" #include "lldb/Target/Process.h" @@ -756,7 +757,7 @@ public: case 's': bool tmp_result; bool success; - tmp_result = Args::StringToBoolean(option_arg, false, &success); + tmp_result = OptionArgParser::ToBoolean(option_arg, false, &success); if (!success) error.SetErrorStringWithFormat("invalid boolean option: \"%s\"", option_arg.str().c_str()); @@ -1440,7 +1441,7 @@ public: bool VerifyCommandOptionValue(const std::string &option, int &real_value) { bool okay = true; bool success = false; - bool tmp_value = Args::StringToBoolean(option, false, &success); + bool tmp_value = OptionArgParser::ToBoolean(option, false, &success); if (success && tmp_value) real_value = 1; -- cgit v1.2.3