summaryrefslogtreecommitdiffstats
path: root/Source/cmGeneratorTarget.cxx
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2019-07-19 01:05:29 (GMT)
committerBrad King <brad.king@kitware.com>2019-07-19 13:58:12 (GMT)
commitc131e62f7bad6638178074cde45f74008067d9de (patch)
treecd857caaa61ed4e33033e2a8c23998b1ce75bce9 /Source/cmGeneratorTarget.cxx
parentfab72918c9ffc862375823daa5a67cceb41cbc1f (diff)
downloadCMake-c131e62f7bad6638178074cde45f74008067d9de.zip
CMake-c131e62f7bad6638178074cde45f74008067d9de.tar.gz
CMake-c131e62f7bad6638178074cde45f74008067d9de.tar.bz2
cmGeneratorTarget: Remove unnecessary copy to local variable
Diffstat (limited to 'Source/cmGeneratorTarget.cxx')
-rw-r--r--Source/cmGeneratorTarget.cxx7
1 files changed, 3 insertions, 4 deletions
diff --git a/Source/cmGeneratorTarget.cxx b/Source/cmGeneratorTarget.cxx
index fe771c6..d2671cd 100644
--- a/Source/cmGeneratorTarget.cxx
+++ b/Source/cmGeneratorTarget.cxx
@@ -2856,12 +2856,11 @@ static void processIncludeDirectories(
if (!cmSystemTools::IsOff(entryInclude)) {
cmSystemTools::ConvertToUnixSlashes(entryInclude);
}
- std::string inc = entryInclude;
- if (uniqueIncludes.insert(inc).second) {
- includes.emplace_back(inc, entry->GetBacktrace());
+ if (uniqueIncludes.insert(entryInclude).second) {
+ includes.emplace_back(entryInclude, entry->GetBacktrace());
if (debugIncludes) {
- usedIncludes += " * " + inc + "\n";
+ usedIncludes += " * " + entryInclude + "\n";
}
}
}