- ::findCommand moves branch pruning out of the iterated loop.
This commit is contained in:
Paul Beckingham 2014-08-22 23:44:18 -04:00
parent 6dad8ddb1b
commit 3fce252461

View file

@ -466,9 +466,9 @@ void Parser::findCommand ()
if (canonicalize (command, "cmd", (*i)->attribute ("raw"))) if (canonicalize (command, "cmd", (*i)->attribute ("raw")))
{ {
(*i)->unTag ("?"); (*i)->unTag ("?");
(*i)->removeAllBranches ();
(*i)->tag ("CMD"); (*i)->tag ("CMD");
(*i)->attribute ("canonical", command); (*i)->attribute ("canonical", command);
(*i)->removeAllBranches ();
if (exactMatch ("writecmd", command)) (*i)->tag ("WRITECMD"); if (exactMatch ("writecmd", command)) (*i)->tag ("WRITECMD");
else if (exactMatch ("readcmd", command)) (*i)->tag ("READCMD"); else if (exactMatch ("readcmd", command)) (*i)->tag ("READCMD");