Documentation ¶
Overview ¶
Package token defines constants representing the lexical tokens of the Ghost programming language and basic operations on tokens.
Index ¶
Constants ¶
View Source
const ( // Special tokens ILLEGAL = "ILLEGAL" EOF = "EOF" // Basic type literals IDENTIFIER = "IDENTIFIER" NUMBER = "NUMBER" STRING = "STRING" // Operators and delimiters PLUS = "+" MINUS = "-" BANG = "!" ASTERISK = "*" SLASH = "/" PERCENT = "%" DOT = "." HASH = "#" LT = "<" GT = ">" LTE = "<=" GTE = ">=" COMMA = "," SEMICOLON = ";" COLON = ":" LPAREN = "(" RPAREN = ")" LBRACE = "{" RBRACE = "}" LBRACKET = "[" RBRACKET = "]" // Keywords FUNCTION = "FUNCTION" TRUE = "TRUE" FALSE = "FALSE" FOR = "FOR" IN = "IN" IF = "IF" ELSE = "ELSE" RETURN = "RETURN" WHILE = "WHILE" AND = "AND" OR = "OR" EXPORT = "EXPORT" IMPORT = "IMPORT" EQ = "==" NOTEQ = "!=" ASSIGN = ":=" PLUSASSIGN = "+=" MINUSASSIGN = "-=" ASTERISKASSIGN = "*=" SLASHASSIGN = "/=" PLUSPLUS = "++" MINUSMINUS = "--" RANGE = ".." )
The list of tokens.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
Click to show internal directories.
Click to hide internal directories.