token

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Mar 1, 2023 License: MIT Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Tokens = [...]string{
	Illegal:  "ILLEGAL",
	EOF:      "EOF",
	Ident:    "IDENT",
	Dot:      ".",
	LBracket: "[",
	RBracket: "]",
	String:   "STRING",
	Int:      "INT",
}

Tokens maps Token constants to their string representations.

Functions

This section is empty.

Types

type Token

type Token int

Token represents a lexical token.

const (
	// special tokens
	Illegal Token = iota
	EOF           // End of File
	WS            // Whitespace

	Ident
	Dot
	LBracket
	RBracket

	// value tokens
	String
	Int
)

Token constants begin with Tok.

Jump to

Keyboard shortcuts

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