MCPcopy Create free account
hub / github.com/AfterShip/clickhouse-sql-parser / peekKeyword

Method peekKeyword

parser/parser_column.go:369–378  ·  view source on GitHub ↗
(keyword string)

Source from the content-addressed store, hash-verified

367}
368
369func (p *Parser) peekKeyword(keyword string) bool {
370 if p.lexer.isEOF() {
371 return false
372 }
373 token, err := p.lexer.peekToken()
374 if err != nil || token == nil {
375 return false
376 }
377 return token.Kind == TokenKindKeyword && strings.EqualFold(token.String, keyword)
378}
379
380// isSelectItemTerminatorKeyword checks whether the current token is a keyword
381// that begins a clause following the SELECT item list. When true, we should not

Callers 2

parseColumnExprMethod · 0.95

Calls 2

isEOFMethod · 0.80
peekTokenMethod · 0.80

Tested by

no test coverage detected