Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Type ¶
type Type string
Type is the set of lexical token types of the Monkey programming language.
const ( ILLEGAL Type = "ILLEGAL" EOF Type = "EOF" // Identifiers + literals IDENT Type = "IDENT" // add, foobar, x, y, ... INT Type = "INT" STRING Type = "STRING" // Operators ASSIGN Type = "=" PLUS Type = "+" MINUS Type = "-" BANG Type = "!" ASTERISK Type = "*" SLASH Type = "/" LT Type = "<" GT Type = ">" EQ Type = "==" NotEQ Type = "!=" // Delimiters COMMA Type = "," SEMICOLON Type = ";" LPAREN Type = "(" RPAREN Type = ")" LBRACE Type = "{" RBRACE Type = "}" LBRACKET Type = "[" RBRACKET Type = "]" COLON Type = ":" // Keywords FUNCTION Type = "FUNCTION" LET Type = "LET" IF Type = "IF" ELSE Type = "ELSE" RETURN Type = "RETURN" FALSE Type = "FALSE" TRUE Type = "TRUE" MACRO Type = "MACRO" )
func LookupIdent ¶
LookupIdent returns the appropriate keyword token type or IDENT
Click to show internal directories.
Click to hide internal directories.