summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lldb/source/Plugins/ObjectFile/ELF/ObjectFileELF.cpp2
-rw-r--r--lldb/tools/lldb-mi/MICmdArgValOptionShort.cpp2
-rw-r--r--lldb/tools/lldb-mi/MICmdArgValString.cpp4
-rw-r--r--lldb/tools/lldb-mi/MICmdCmdData.cpp6
-rw-r--r--lldb/tools/lldb-mi/MICmdFactory.cpp2
-rw-r--r--lldb/tools/lldb-mi/MICmdInterpreter.cpp8
6 files changed, 12 insertions, 12 deletions
diff --git a/lldb/source/Plugins/ObjectFile/ELF/ObjectFileELF.cpp b/lldb/source/Plugins/ObjectFile/ELF/ObjectFileELF.cpp
index f9cec241538..fd388026d51 100644
--- a/lldb/source/Plugins/ObjectFile/ELF/ObjectFileELF.cpp
+++ b/lldb/source/Plugins/ObjectFile/ELF/ObjectFileELF.cpp
@@ -1558,7 +1558,7 @@ ObjectFileELF::GetSegmentDataByIndex(lldb::user_id_t id)
std::string
ObjectFileELF::StripLinkerSymbolAnnotations(llvm::StringRef symbol_name) const
{
- size_t pos = symbol_name.find("@");
+ size_t pos = symbol_name.find('@');
return symbol_name.substr(0, pos).str();
}
diff --git a/lldb/tools/lldb-mi/MICmdArgValOptionShort.cpp b/lldb/tools/lldb-mi/MICmdArgValOptionShort.cpp
index 25eac676f5f..d18f72eaa8b 100644
--- a/lldb/tools/lldb-mi/MICmdArgValOptionShort.cpp
+++ b/lldb/tools/lldb-mi/MICmdArgValOptionShort.cpp
@@ -80,7 +80,7 @@ CMICmdArgValOptionShort::IsArgShortOption(const CMIUtilString &vrTxt) const
return false;
// Look for -f short option
- nPos = vrTxt.find("-");
+ nPos = vrTxt.find('-');
if (nPos != 0)
return false;
diff --git a/lldb/tools/lldb-mi/MICmdArgValString.cpp b/lldb/tools/lldb-mi/MICmdArgValString.cpp
index c8d32901a4e..1c3e5f84d3d 100644
--- a/lldb/tools/lldb-mi/MICmdArgValString.cpp
+++ b/lldb/tools/lldb-mi/MICmdArgValString.cpp
@@ -231,11 +231,11 @@ CMICmdArgValString::IsStringArgSingleText(const CMIUtilString &vrTxt) const
return false;
// Look for -f type short options, if found reject
- if ((0 == vrTxt.find("-")) && (vrTxt.length() == 2))
+ if ((0 == vrTxt.find('-')) && (vrTxt.length() == 2))
return false;
// Look for thread group i1 i2 i3...., if found reject
- if ((vrTxt.find("i") == 0) && ::isdigit(vrTxt[1]))
+ if ((vrTxt.find('i') == 0) && ::isdigit(vrTxt[1]))
return false;
// Look for numbers, if found reject
diff --git a/lldb/tools/lldb-mi/MICmdCmdData.cpp b/lldb/tools/lldb-mi/MICmdCmdData.cpp
index bd0209337cd..0b950d5a4c4 100644
--- a/lldb/tools/lldb-mi/MICmdCmdData.cpp
+++ b/lldb/tools/lldb-mi/MICmdCmdData.cpp
@@ -1750,8 +1750,8 @@ CMICmdCmdDataInfoLine::Acknowledge(void)
// LineEntry: \[0x0000000100000f37-0x0000000100000f45\): /path/to/file:3[:1]
// ^^^^^^^^^^^^^^^^^^ -- start address
- const size_t nStartAddressStartPos = rLine.find("[");
- const size_t nStartAddressEndPos = rLine.find("-");
+ const size_t nStartAddressStartPos = rLine.find('[');
+ const size_t nStartAddressEndPos = rLine.find('-');
const size_t nStartAddressLen = nStartAddressEndPos - nStartAddressStartPos - 1;
const CMIUtilString strStartAddress(rLine.substr(nStartAddressStartPos + 1, nStartAddressLen).c_str());
const CMICmnMIValueConst miValueConst(strStartAddress);
@@ -1760,7 +1760,7 @@ CMICmdCmdDataInfoLine::Acknowledge(void)
// LineEntry: \[0x0000000100000f37-0x0000000100000f45\): /path/to/file:3[:1]
// ^^^^^^^^^^^^^^^^^^ -- end address
- const size_t nEndAddressEndPos = rLine.find(")");
+ const size_t nEndAddressEndPos = rLine.find(')');
const size_t nEndAddressLen = nEndAddressEndPos - nStartAddressEndPos - 1;
const CMIUtilString strEndAddress(rLine.substr(nStartAddressEndPos + 1, nEndAddressLen).c_str());
const CMICmnMIValueConst miValueConst2(strEndAddress);
diff --git a/lldb/tools/lldb-mi/MICmdFactory.cpp b/lldb/tools/lldb-mi/MICmdFactory.cpp
index 3fe4062b772..ffad60910d0 100644
--- a/lldb/tools/lldb-mi/MICmdFactory.cpp
+++ b/lldb/tools/lldb-mi/MICmdFactory.cpp
@@ -159,7 +159,7 @@ CMICmdFactory::IsValid(const CMIUtilString &vMiCmd) const
return false;
}
- const size_t nPos = vMiCmd.find(" ");
+ const size_t nPos = vMiCmd.find(' ');
if (nPos != std::string::npos)
bValid = false;
diff --git a/lldb/tools/lldb-mi/MICmdInterpreter.cpp b/lldb/tools/lldb-mi/MICmdInterpreter.cpp
index ce5d30e9231..3c5285fc8cc 100644
--- a/lldb/tools/lldb-mi/MICmdInterpreter.cpp
+++ b/lldb/tools/lldb-mi/MICmdInterpreter.cpp
@@ -153,7 +153,7 @@ bool
CMICmdInterpreter::MiHasCmdTokenEndingHyphen(const CMIUtilString &vTextLine)
{
// The hyphen is mandatory
- const size_t nPos = vTextLine.find("-", 0);
+ const size_t nPos = vTextLine.find('-', 0);
if ((nPos == std::string::npos))
return false;
@@ -215,7 +215,7 @@ CMICmdInterpreter::MiHasCmdTokenEndingAlpha(const CMIUtilString &vTextLine)
bool
CMICmdInterpreter::MiHasCmdTokenPresent(const CMIUtilString &vTextLine)
{
- const size_t nPos = vTextLine.find("-", 0);
+ const size_t nPos = vTextLine.find('-', 0);
return (nPos > 0);
}
@@ -246,12 +246,12 @@ CMICmdInterpreter::MiHasCmd(const CMIUtilString &vTextLine)
}
else
{
- nPos = vTextLine.find("-", 0);
+ nPos = vTextLine.find('-', 0);
}
bool bFoundCmd = false;
const size_t nLen = vTextLine.length();
- const size_t nPos2 = vTextLine.find(" ", nPos);
+ const size_t nPos2 = vTextLine.find(' ', nPos);
if (nPos2 != std::string::npos)
{
if (nPos2 == nLen)
OpenPOWER on IntegriCloud