performance: Use ascii-only version of getUnitl for parsing attribute names

Not having to consider utf-8 characters has performance benefits.
This commit is contained in:
Tomas Babej 2021-04-24 09:30:08 -04:00
parent 95b135b59e
commit 87d0499fc8

View file

@ -596,8 +596,8 @@ void Task::parse (const std::string& input)
std::string value; std::string value;
while (!attLine.eos ()) while (!attLine.eos ())
{ {
if (attLine.getUntil (':', name) && if (attLine.getUntilAscii (':', name) &&
attLine.skip (':') && attLine.skip (':') &&
attLine.getQuoted ('"', value)) attLine.getQuoted ('"', value))
{ {
#ifdef PRODUCT_TASKWARRIOR #ifdef PRODUCT_TASKWARRIOR