Documentation
¶
Index ¶
Constants ¶
View Source
const IDENT_CHARS = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789_?!"
View Source
const LEGAL_IDENT_CHARS = "?!"
View Source
const OPERATOR_CHARS = "+-*/%&<>=,;#.:(){}[]|@$?!"
NOTE: Overlap of `?` and `!`
Variables ¶
View Source
var LexStartFn = startLexer
LexStartFn represents the entrypoint the Lexer uses to start processing the input.
Functions ¶
This section is empty.
Types ¶
type Lexer ¶
type Lexer struct {
// contains filtered or unexported fields
}
Lexer is the engine to process input and emit Tokens
type StateFn ¶
StateFn represents a function which is capable of lexing parts of the input. It returns another StateFn to proceed with.
Typically a state function would get called from LexStartFn and should return LexStartFn to go back to the decision loop. It also could return another non start state function if the partial input to parse is abiguous.
Click to show internal directories.
Click to hide internal directories.