MCPcopy Create free account
hub / github.com/ajitpratap0/GoSQLX / advance

Method advance

pkg/sql/parser/parser.go:853–860  ·  view source on GitHub ↗

advance moves to the next token

()

Source from the content-addressed store, hash-verified

851
852// advance moves to the next token
853func (p *Parser) advance() {
854 p.currentPos++
855 if p.currentPos < len(p.tokens) {
856 p.currentToken = p.tokens[p.currentPos]
857 } else {
858 p.currentToken = models.TokenWithSpan{} // EOF sentinel
859 }
860}
861
862// peekToken returns the next token without advancing the parser position.
863// Returns an empty TokenWithSpan if at the end of input.

Callers 15

parseCreateStatementMethod · 0.95
parseCreateTableMethod · 0.95
parseDropStatementMethod · 0.95
parseMergeStatementMethod · 0.95
parseMergeWhenClauseMethod · 0.95
parseMergeActionMethod · 0.95
synchronizeMethod · 0.95
parseWithRecoveryMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected