diff --git a/Source/cmSetCommand.cxx b/Source/cmSetCommand.cxx index 90d7b0395..204d95b1e 100644 --- a/Source/cmSetCommand.cxx +++ b/Source/cmSetCommand.cxx @@ -108,17 +108,7 @@ bool cmSetCommand } // collect any values into a single semi-colon separated value list - if(static_cast(args.size()) > - static_cast(1 + ignoreLastArgs)) - { - value = args[1]; - size_t endPos = args.size() - ignoreLastArgs; - for(size_t i = 2; i < endPos; ++i) - { - value += ";"; - value += args[i]; - } - } + value = cmJoin(cmRange(args).advance(1).retreat(ignoreLastArgs), ";"); if (parentScope) {