summaryrefslogtreecommitdiffstats
path: root/Source/cmDependsC.cxx
diff options
context:
space:
mode:
authorVitaly Stakhovsky <vvs31415@gitlab.org>2018-08-07 15:27:20 (GMT)
committerBrad King <brad.king@kitware.com>2018-08-07 19:28:24 (GMT)
commit69ca85cc7faf937d6d9d1dc1a27e062cd7765b1f (patch)
treef323fcadf3c4e11227a0eea006ae7bfa17e8d26c /Source/cmDependsC.cxx
parentd7a52f8c24a29ff7f64b00566b646f2d125d4ac0 (diff)
downloadCMake-69ca85cc7faf937d6d9d1dc1a27e062cd7765b1f.zip
CMake-69ca85cc7faf937d6d9d1dc1a27e062cd7765b1f.tar.gz
CMake-69ca85cc7faf937d6d9d1dc1a27e062cd7765b1f.tar.bz2
Remove unnecessary c_str() in RegularExpression::find calls
Diffstat (limited to 'Source/cmDependsC.cxx')
-rw-r--r--Source/cmDependsC.cxx8
1 files changed, 4 insertions, 4 deletions
diff --git a/Source/cmDependsC.cxx b/Source/cmDependsC.cxx
index 34c0e94..f7dd33b 100644
--- a/Source/cmDependsC.cxx
+++ b/Source/cmDependsC.cxx
@@ -174,7 +174,7 @@ bool cmDependsC::WriteDependencies(const std::set<std::string>& sources,
// Complain if the file cannot be found and matches the complain
// regex.
if (fullName.empty() &&
- this->IncludeRegexComplain.find(current.FileName.c_str())) {
+ this->IncludeRegexComplain.find(current.FileName)) {
cmSystemTools::Error("Cannot find file \"", current.FileName.c_str(),
"\".");
return false;
@@ -359,7 +359,7 @@ void cmDependsC::Scan(std::istream& is, const char* directory,
}
// Match include directives.
- if (this->IncludeRegexLine.find(line.c_str())) {
+ if (this->IncludeRegexLine.find(line)) {
// Get the file being included.
UnscannedEntry entry;
entry.FileName = this->IncludeRegexLine.match(2);
@@ -383,7 +383,7 @@ void cmDependsC::Scan(std::istream& is, const char* directory,
// file their own directory by simply using "filename.h" (#12619)
// This kind of problem will be fixed when a more
// preprocessor-like implementation of this scanner is created.
- if (this->IncludeRegexScan.find(entry.FileName.c_str())) {
+ if (this->IncludeRegexScan.find(entry.FileName)) {
newCacheEntry->UnscannedEntries.push_back(entry);
if (this->Encountered.find(entry.FileName) ==
this->Encountered.end()) {
@@ -449,7 +449,7 @@ void cmDependsC::ParseTransform(std::string const& xform)
void cmDependsC::TransformLine(std::string& line)
{
// Check for a transform rule match. Return if none.
- if (!this->IncludeRegexTransform.find(line.c_str())) {
+ if (!this->IncludeRegexTransform.find(line)) {
return;
}
TransformRulesType::const_iterator tri =