Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var NullToken = Token{ Type: NULLTOKEN, }
Functions ¶
This section is empty.
Types ¶
type TokenError ¶
type TokenError struct {
// contains filtered or unexported fields
}
TokenError is error
func (TokenError) Error ¶
func (e TokenError) Error() string
type TokenType ¶
type TokenType int
const ( NULLTOKEN TokenType = iota // No Token LEFTPAREN // "(" RIGHTPAREN // ")" LEFTBRACE // "{" RIGHTBRACE // "}" COMMA // "," DOT // "." MINUS // "-" PLUS // "+" SEMICOLON // ";" DIVIDE // "/" MULTIPLY // "*" BANG // "!" BANGEQUAL // "!=" EQUAL // "=" DOUBLEEQUAL // "==" GREATER // ">" GREATEREQUAL // ">=" LESS // "<" LESSEQUAL // "<=" IDENTIFIER // E.g. "i" STRING // E.g. "Hello" NUMBER // E.g. 42, 3.14 AND // && OR // "||" CLASS // "class" ELSE // "else" FALSE // "false" FUN // "fun" FOR // "for" IF // "if" NIL // "nil" PRINT // "print" RETURN // "return" SUPER // "super" THIS // "this" TRUE // "true" VAR // "var" WHILE // "while" EOF // "EOF" COMMENT // "// This is a comment" )
Click to show internal directories.
Click to hide internal directories.