Change to ANTLR Lexer

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view

Change to ANTLR Lexer

Koji Kawamura
Hi team,

I'm trying to fix a part of ANTLR Lexer that hasn't been updated since
NiFi is released. Since would like to have more reviewers and comments
if possible.

Ed, Otto and I have been working on
NIFI-5826 UpdateRecord processor throwing PatternSyntaxException

We identified that the cause is RecordPathLexer.g converts
 an escaped square-bracket '\['
 to an escaped back-slash and square-bracket '\\['

Specifically, RecordPathLexer.g 'ESC' fragment does that conversion.
Also, AttributeExpressionLexer and HL7QueryLexer have the same
definition (and issue).

There is detailed explanation on this PR's description.

I will hold merging this PR even if Ed and Otto give +1, to make
enough time for other reviewers, at least for another week.
Any comment would be appreciated. Something like:
- Suggestions to add more unit tests, input and expectation
- The original intent of converting a single back-slash to doubled (if
anyone knows)
- "We should hold this until NiFi 2.0" (not my preference though)
... etc

Thanks in advance!