Merge topic 'fix-genex-split-duplication'
f93a388
Fix the cmGeneratorExpression::Split when leading chars are present.
This commit is contained in:
commit
91d86838a9
|
@ -302,13 +302,21 @@ void cmGeneratorExpression::Split(const std::string &input,
|
|||
if (!part.empty())
|
||||
{
|
||||
std::string::size_type startPos = input.rfind(";", pos);
|
||||
if (startPos != pos - 1 && startPos >= lastPos)
|
||||
if (startPos == std::string::npos)
|
||||
{
|
||||
preGenex = part;
|
||||
part = "";
|
||||
}
|
||||
else if (startPos != pos - 1 && startPos >= lastPos)
|
||||
{
|
||||
part = input.substr(lastPos, startPos - lastPos);
|
||||
preGenex = input.substr(startPos + 1, pos - startPos - 1);
|
||||
}
|
||||
if(!part.empty())
|
||||
{
|
||||
cmSystemTools::ExpandListArgument(part.c_str(), output);
|
||||
}
|
||||
}
|
||||
pos += 2;
|
||||
int nestingLevel = 1;
|
||||
const char *c = input.c_str() + pos;
|
||||
|
|
Loading…
Reference in New Issue