teragrep / pth_03

Data Processing Language (DPL) parser
GNU Affero General Public License v3.0
0 stars 4 forks source link

Savedsearch does not recognize strEQstrParameter #44

Open 51-code opened 1 month ago

51-code commented 1 month ago

Describe the bug

With a query like: | savedsearch a b=c The parser stops parsing at the token "b", even though it should be a proper way to use the command. "b=c" is the strEQstrParameter in the grammar.

This is the error message:

line 46:18 mismatched input 'b' expecting {PIPE, GET_FIELD_SINGLE_QUOTED, GET_FIELD_DOUBLE_QUOTED, GET_FIELD_STRING, 'nosubstitution='}

Doesn't help if whitespace is added to before or after the equals sign (b = c) or if double quotes are added to the "c", which should probably be there anyways.

Expected behavior

Should be proper grammar and parse correctly.

How to reproduce

Print the parse tree for the query above.

Screenshots

Software version

6.1.0

Desktop (please complete the following information if relevant):

Additional context

savedsearchSyntaxParseTest in SavedsearchSyntaxTests.java has been disabled because of this issue in PR #52.