Commit 416df93a authored by Stephen Kelly's avatar Stephen Kelly

Convert some raw loops to cmWrap.

parent 37b88d34
......@@ -705,10 +705,7 @@ void cmComputeLinkDepends::DisplayConstraintGraph()
{
EdgeList const& nl = this->EntryConstraintGraph[i];
e << "item " << i << " is [" << this->EntryList[i].Item << "]\n";
for(EdgeList::const_iterator j = nl.begin(); j != nl.end(); ++j)
{
e << " item " << *j << " must follow it\n";
}
e << cmWrap(" item ", nl, " must follow it", "\n") << "\n";
}
fprintf(stderr, "%s\n", e.str().c_str());
}
......
......@@ -683,11 +683,9 @@ void cmCoreTryCompile::FindOutputFile(const std::string& targetName)
std::ostringstream emsg;
emsg << "Unable to find the executable at any of:\n";
for (unsigned int i = 0; i < searchDirs.size(); ++i)
{
emsg << " " << this->BinaryDirectory << searchDirs[i]
<< tmpOutputFile << "\n";
}
emsg << cmWrap(" " + this->BinaryDirectory,
searchDirs,
tmpOutputFile, "\n") << "\n";
this->FindErrorMessage = emsg.str();
return;
}
......@@ -355,11 +355,7 @@ void cmFindBase::PrintFindStuff()
std::cerr << "SearchPathSuffixes ";
std::cerr << cmJoin(this->SearchPathSuffixes, "\n") << "\n";
std::cerr << "SearchPaths\n";
for(std::vector<std::string>::const_iterator i = this->SearchPaths.begin();
i != this->SearchPaths.end(); ++i)
{
std::cerr << "[" << *i << "]\n";
}
std::cerr << cmWrap("[", this->SearchPaths, "]", "\n") << "\n";
}
bool cmFindBase::CheckForVariableInCache()
......
......@@ -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 "
......
......@@ -213,13 +213,7 @@ cmMakefile::~cmMakefile()
void cmMakefile::PrintStringVector(const char* s,
const std::vector<std::string>& v) const
{
std::cout << s << ": ( \n";
for(std::vector<std::string>::const_iterator i = v.begin();
i != v.end(); ++i)
{
std::cout << *i << " ";
}
std::cout << " )\n";
std::cout << s << ": ( \n" << cmWrap('"', v, '"', " ") << ")\n";
}
void cmMakefile
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment