MCPcopy Create free account
hub / github.com/cockroachdb/cockroachdb-parser / lastToken

Method lastToken

pkg/sql/parser/lexer.go:314–327  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

312}
313
314func (l *lexer) lastToken() sqlSymType {
315 if l.lastPos < 0 {
316 return sqlSymType{}
317 }
318
319 if l.lastPos >= len(l.tokens) {
320 return sqlSymType{
321 id: 0,
322 pos: int32(len(l.in)),
323 str: "EOF",
324 }
325 }
326 return l.tokens[l.lastPos]
327}
328
329// NewAnnotation returns a new annotation index.
330func (l *lexer) NewAnnotation() tree.AnnotationIdx {

Callers 2

populateErrorDetailsMethod · 0.95
SetHelpMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected