summaryrefslogtreecommitdiffstats
path: root/Source/cmFindPackageCommand.cxx
diff options
context:
space:
mode:
authorStephen Kelly <steveire@gmail.com>2015-02-18 21:14:26 (GMT)
committerStephen Kelly <steveire@gmail.com>2015-02-20 20:36:57 (GMT)
commit416df93aa93d0a633f0e7354d0562934f676768b (patch)
tree11937ca00d29012dad0f84e5ab7b93ee374de257 /Source/cmFindPackageCommand.cxx
parent37b88d348a20921c835ce7aa99f6db62271503a7 (diff)
downloadCMake-416df93aa93d0a633f0e7354d0562934f676768b.zip
CMake-416df93aa93d0a633f0e7354d0562934f676768b.tar.gz
CMake-416df93aa93d0a633f0e7354d0562934f676768b.tar.bz2
Convert some raw loops to cmWrap.
Diffstat (limited to 'Source/cmFindPackageCommand.cxx')
-rw-r--r--Source/cmFindPackageCommand.cxx14
1 files changed, 3 insertions, 11 deletions
diff --git a/Source/cmFindPackageCommand.cxx b/Source/cmFindPackageCommand.cxx
index fd9b236..26bd4b9 100644
--- a/Source/cmFindPackageCommand.cxx
+++ b/Source/cmFindPackageCommand.cxx
@@ -329,10 +329,7 @@ bool cmFindPackageCommand
{
std::ostringstream e;
e << "called with components that are both required and optional:\n";
- for(unsigned int i=0; i<doubledComponents.size(); ++i)
- {
- e << " " << doubledComponents[i] << "\n";
- }
+ e << cmWrap(" ", doubledComponents, "", "\n") << "\n";
this->SetError(e.str());
return false;
}
@@ -808,13 +805,8 @@ bool cmFindPackageCommand::HandlePackageMode()
{
e << "Could not find a package configuration file provided by \""
<< this->Name << "\"" << requestedVersionString
- << " with any of the following names:\n";
- for(std::vector<std::string>::const_iterator ci =
- this->Configs.begin();
- ci != this->Configs.end(); ++ci)
- {
- e << " " << *ci << "\n";
- }
+ << " with any of the following names:\n"
+ << cmWrap(" ", this->Configs, "", "\n") << "\n";
}
e << "Add the installation prefix of \"" << this->Name << "\" to "