summaryrefslogtreecommitdiffstats
path: root/Source/cmTargetCompileDefinitionsCommand.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'Source/cmTargetCompileDefinitionsCommand.cxx')
-rw-r--r--Source/cmTargetCompileDefinitionsCommand.cxx9
1 files changed, 4 insertions, 5 deletions
diff --git a/Source/cmTargetCompileDefinitionsCommand.cxx b/Source/cmTargetCompileDefinitionsCommand.cxx
index 008d1a2..d159d41 100644
--- a/Source/cmTargetCompileDefinitionsCommand.cxx
+++ b/Source/cmTargetCompileDefinitionsCommand.cxx
@@ -41,12 +41,11 @@ std::string cmTargetCompileDefinitionsCommand::Join(
{
std::string defs;
std::string sep;
- for (std::vector<std::string>::const_iterator it = content.begin();
- it != content.end(); ++it) {
- if (cmHasLiteralPrefix(it->c_str(), "-D")) {
- defs += sep + it->substr(2);
+ for (std::string const& it : content) {
+ if (cmHasLiteralPrefix(it.c_str(), "-D")) {
+ defs += sep + it.substr(2);
} else {
- defs += sep + *it;
+ defs += sep + it;
}
sep = ";";
}