s5dsn-eqee commented on code in PR #2620:
URL:
https://github.com/apache/datafusion-sqlparser-rs/pull/2620#discussion_r4325133958
##########
src/parser/mod.rs:
##########
@@ -14197,11 +14197,10 @@ impl<'a> Parser<'a> {
}
}
- // If the last segment was a number, we must check that
it's followed by whitespace,
- // otherwise foo-123a will be parsed as `foo-123` with the
alias `a`.
+ // A word or number butted onto a trailing number glues
into it, as in `foo-123a`.
if requires_whitespace {
- let token = self.next_token();
- if !matches!(token.token, Token::EOF |
Token::Whitespace(_)) {
+ let token = self.peek_token_no_skip();
Review Comment:
👍
--
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]