LucaCappelletti94 opened a new pull request, #2419:
URL: https://github.com/apache/datafusion-sqlparser-rs/pull/2419
`SQLiteDialect::parse_infix` parsed the right operand of `REGEXP`, `MATCH`,
and `GLOB` with `parse_expr`, and previously lead to mutating the meaning of
boolean operations constructed with it.
For instance, `a REGEXP 'p' AND b = 1` parsed as a `REGEXP ('p' AND b = 1)`
instead of `(a REGEXP 'p') AND (b = 1)`.
The hook was ignoring the precedence its caller passed, so using it fixes
all three. Nothing errored before, and Display adds no parentheses, so the
wrong tree reprinted as the original text. That is why a text round trip never
caught it and the new test asserts on the tree instead.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]