lexer

package
v0.0.0-...-0e7933b Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 22, 2022 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Lexer

type Lexer struct {
	Mode Mode // scanning mode
	// contains filtered or unexported fields
}

func New

func New(filename, input string) *Lexer

func (*Lexer) NextInterpToken

func (l *Lexer) NextInterpToken() token.Token

func (*Lexer) NextInterpToken2

func (l *Lexer) NextInterpToken2() token.Token

for date-time literal handling

func (*Lexer) NextToken

func (l *Lexer) NextToken() token.Token

func (*Lexer) SetMode

func (l *Lexer) SetMode(mode Mode)

type Mode

type Mode uint

A mode value is a set of flags (or 0). They control scanner behavior.

const (
	ScanComments Mode = 1 << iota // return comments as COMMENT tokens

)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL