CTest: Expand a string directly into a container.

Change the follow-up loop to use a const_iterator to log the
content.
This commit is contained in:
Stephen Kelly 2014-12-18 21:10:44 +01:00
parent cd7bde80bf
commit 722f1a71e3
1 changed files with 3 additions and 5 deletions

View File

@ -2598,16 +2598,14 @@ void cmCTest::PopulateCustomVector(cmMakefile* mf, const std::string& def,
return;
}
cmCTestLog(this, DEBUG, "PopulateCustomVector: " << def << std::endl);
std::vector<std::string> slist;
cmSystemTools::ExpandListArgument(dval, slist);
std::vector<std::string>::iterator it;
vec.clear();
cmSystemTools::ExpandListArgument(dval, vec);
for ( it = slist.begin(); it != slist.end(); ++it )
for (std::vector<std::string>::const_iterator it = vec.begin();
it != vec.end(); ++it )
{
cmCTestLog(this, DEBUG, " -- " << *it << std::endl);
vec.push_back(*it);
}
}