CLI
- Added debug.parser=3 support to ::expandAlias.
This commit is contained in:
@@ -537,6 +537,7 @@ void CLI::addArg (const std::string& arg)
|
|||||||
////////////////////////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////////////////////////
|
||||||
void CLI::aliasExpansion ()
|
void CLI::aliasExpansion ()
|
||||||
{
|
{
|
||||||
|
bool changes = false;
|
||||||
bool action;
|
bool action;
|
||||||
int counter = 0;
|
int counter = 0;
|
||||||
do
|
do
|
||||||
@@ -571,6 +572,7 @@ void CLI::aliasExpansion ()
|
|||||||
}
|
}
|
||||||
|
|
||||||
action = true;
|
action = true;
|
||||||
|
changes = true;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
reconstructed.push_back (*i);
|
reconstructed.push_back (*i);
|
||||||
@@ -582,6 +584,10 @@ void CLI::aliasExpansion ()
|
|||||||
_args = reconstructed;
|
_args = reconstructed;
|
||||||
}
|
}
|
||||||
while (action && counter++ < safetyValveDefault);
|
while (action && counter++ < safetyValveDefault);
|
||||||
|
|
||||||
|
if (changes &&
|
||||||
|
context.config.getInteger ("debug.parser") >= 3)
|
||||||
|
context.debug (context.cli.dump ("CLI::analyze aliasExpansion"));
|
||||||
}
|
}
|
||||||
|
|
||||||
////////////////////////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////////////////////////
|
||||||
|
|||||||
Reference in New Issue
Block a user