mirror of
https://github.com/apache/datafusion-sqlparser-rs.git
synced 2025-08-02 13:12:16 +00:00
Introduce location tracking in the tokenizer and parser (#710)
* Add locations * Add PartialEq * Add PartialEq * Add some tests * Fix rebase conflicts * Fix clippy Co-authored-by: Andrew Lamb <andrew@nerdnetworks.org>
This commit is contained in:
parent
512a159f08
commit
813f4a2eff
4 changed files with 404 additions and 174 deletions
|
@ -52,7 +52,7 @@ pub fn parse_comment(parser: &mut Parser) -> Result<Statement, ParserError> {
|
|||
parser.expect_keyword(Keyword::ON)?;
|
||||
let token = parser.next_token();
|
||||
|
||||
let (object_type, object_name) = match token {
|
||||
let (object_type, object_name) = match token.token {
|
||||
Token::Word(w) if w.keyword == Keyword::COLUMN => {
|
||||
let object_name = parser.parse_object_name()?;
|
||||
(CommentObject::Column, object_name)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue