summaryrefslogtreecommitdiff
path: root/Source/cmDependsFortran.cxx
diff options
context:
space:
mode:
authorArtur Ryt <artur.ryt@gmail.com>2019-03-30 16:11:21 +0100
committerArtur Ryt <artur.ryt@gmail.com>2019-03-30 16:15:05 +0100
commit2d66567dca2a5a80e41493ec0a9d6d86f7d955f5 (patch)
tree84468e248f456f65c75a99033ba8073e48ea0f5b /Source/cmDependsFortran.cxx
parent5bdee3786359b6560eb9ee1d6fab8664feb90db4 (diff)
downloadcmake-2d66567dca2a5a80e41493ec0a9d6d86f7d955f5.tar.gz
Modernize: Prefer .substr in place of .c_str() + int
A lot of temporary/local strings were created out of C-strings substr can utilize current string size, so in theory be a little more efficient.
Diffstat (limited to 'Source/cmDependsFortran.cxx')
-rw-r--r--Source/cmDependsFortran.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/Source/cmDependsFortran.cxx b/Source/cmDependsFortran.cxx
index 3f036a9de9..178e18b5f0 100644
--- a/Source/cmDependsFortran.cxx
+++ b/Source/cmDependsFortran.cxx
@@ -295,7 +295,7 @@ void cmDependsFortran::MatchRemoteModules(std::istream& fin,
// They do not include the ".mod" extension.
mod += ".mod";
}
- this->ConsiderModule(mod.c_str() + 1, stampDir);
+ this->ConsiderModule(mod.substr(1), stampDir);
}
} else if (line == "provides") {
doing_provides = true;