diff options
author | Dimitry Andric <dim@FreeBSD.org> | 2015-12-30 11:55:28 +0000 |
---|---|---|
committer | Dimitry Andric <dim@FreeBSD.org> | 2015-12-30 11:55:28 +0000 |
commit | e81d9d49145e432d917eea3a70d2ae74dcad1d89 (patch) | |
tree | 9ed5e1a91f242e2cb5911577356e487a55c01b78 /tools/lldb-mi/MICmdInterpreter.cpp | |
parent | 85d8ef8f1f0e0e063a8571944302be2d2026f823 (diff) |
Notes
Diffstat (limited to 'tools/lldb-mi/MICmdInterpreter.cpp')
-rw-r--r-- | tools/lldb-mi/MICmdInterpreter.cpp | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/tools/lldb-mi/MICmdInterpreter.cpp b/tools/lldb-mi/MICmdInterpreter.cpp index 3c5285fc8cc89..1abcc9a3f4276 100644 --- a/tools/lldb-mi/MICmdInterpreter.cpp +++ b/tools/lldb-mi/MICmdInterpreter.cpp @@ -18,7 +18,7 @@ // Return: None. // Throws: None. //-- -CMICmdInterpreter::CMICmdInterpreter(void) +CMICmdInterpreter::CMICmdInterpreter() : m_rCmdFactory(CMICmdFactory::Instance()) { } @@ -30,7 +30,7 @@ CMICmdInterpreter::CMICmdInterpreter(void) // Return: None. // Throws: None. //-- -CMICmdInterpreter::~CMICmdInterpreter(void) +CMICmdInterpreter::~CMICmdInterpreter() { Shutdown(); } @@ -44,7 +44,7 @@ CMICmdInterpreter::~CMICmdInterpreter(void) // Throws: None. //-- bool -CMICmdInterpreter::Initialize(void) +CMICmdInterpreter::Initialize() { m_clientUsageRefCnt++; @@ -65,7 +65,7 @@ CMICmdInterpreter::Initialize(void) // Throws: None. //-- bool -CMICmdInterpreter::Shutdown(void) +CMICmdInterpreter::Shutdown() { if (--m_clientUsageRefCnt > 0) return MIstatus::success; @@ -160,10 +160,10 @@ CMICmdInterpreter::MiHasCmdTokenEndingHyphen(const CMIUtilString &vTextLine) if (MiHasCmdTokenPresent(vTextLine)) { const std::string strNum = vTextLine.substr(0, nPos); - if (!CMIUtilString(strNum.c_str()).IsNumber()) + if (!CMIUtilString(strNum).IsNumber()) return false; - m_miCmdData.strMiCmdToken = strNum.c_str(); + m_miCmdData.strMiCmdToken = strNum; } m_miCmdData.bMIOldStyle = false; @@ -256,20 +256,20 @@ CMICmdInterpreter::MiHasCmd(const CMIUtilString &vTextLine) { if (nPos2 == nLen) return false; - const CMIUtilString cmd = CMIUtilString(vTextLine.substr(nPos + 1, nPos2 - nPos - 1).c_str()); + const CMIUtilString cmd = CMIUtilString(vTextLine.substr(nPos + 1, nPos2 - nPos - 1)); if (cmd.empty()) return false; m_miCmdData.strMiCmd = cmd; if (nPos2 < nLen) - m_miCmdData.strMiCmdOption = CMIUtilString(vTextLine.substr(nPos2 + 1, nLen - nPos2 - 1).c_str()); + m_miCmdData.strMiCmdOption = CMIUtilString(vTextLine.substr(nPos2 + 1, nLen - nPos2 - 1)); bFoundCmd = true; } else { - const CMIUtilString cmd = CMIUtilString(vTextLine.substr(nPos + 1, nLen - nPos - 1).c_str()); + const CMIUtilString cmd = CMIUtilString(vTextLine.substr(nPos + 1, nLen - nPos - 1)); if (cmd.empty()) return false; m_miCmdData.strMiCmd = cmd; @@ -291,7 +291,7 @@ CMICmdInterpreter::MiHasCmd(const CMIUtilString &vTextLine) // Throws: None. //-- const SMICmdData & -CMICmdInterpreter::MiGetCmdData(void) const +CMICmdInterpreter::MiGetCmdData() const { return m_miCmdData; } |