CLI2: Apply desugaring of plain filter args to date args

This ensures that commands like `task marc` perform description
substring search on `marc`.

Closes #2451.
This commit is contained in:
Tomas Babej 2021-04-14 02:21:34 -04:00 committed by Tomas Babej
parent 475a16b3d4
commit bd0d907335

View file

@ -1884,6 +1884,7 @@ void CLI2::lexFilterArgs ()
// - neither argX nor argY are an operator, except (, ), and, or, xor
// - candidate is one of: Lexer::Type::word
// Lexer::Type::identifier
// Lexer::Type::date
//
void CLI2::desugarFilterPlainArgs ()
{
@ -1905,6 +1906,7 @@ void CLI2::desugarFilterPlainArgs ()
ppraw == "xor") &&
(prev->_lextype == Lexer::Type::identifier || // candidate
prev->_lextype == Lexer::Type::date || // candidate
prev->_lextype == Lexer::Type::word) && // candidate
prev->hasTag ("FILTER") && // candidate