cmFindBase: Replace loop with cmJoin on range.
This commit is contained in:
parent
9380e85f86
commit
0ea719326e
|
@ -166,11 +166,9 @@ bool cmFindBase::ParseArguments(std::vector<std::string> const& argsIn)
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
this->VariableDocumentation += "one of the " + this->Names[0];
|
this->VariableDocumentation += "one of the ";
|
||||||
for (unsigned int j = 1; j < this->Names.size() - 1; ++j)
|
this->VariableDocumentation += cmJoin(cmRange(this->Names).retreat(1),
|
||||||
{
|
", ");
|
||||||
this->VariableDocumentation += ", " + this->Names[j];
|
|
||||||
}
|
|
||||||
this->VariableDocumentation += " or "
|
this->VariableDocumentation += " or "
|
||||||
+ this->Names[this->Names.size() - 1] + " libraries be found";
|
+ this->Names[this->Names.size() - 1] + " libraries be found";
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue