token

package
v0.0.0-...-d03bbad Latest Latest
Warning

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

Go to latest
Published: Aug 7, 2018 License: MIT Imports: 1 Imported by: 4

Documentation

Overview

Package token exports the grammar's lexical tokens.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsNumber

func IsNumber(t Type) bool

func IsUnaryOperator

func IsUnaryOperator(t Type) bool

Types

type Type

type Type int

Type of tokens

const (
	Illegal Type = iota
	Bool
	Decimal
	Hexadecimal
	Octal
	String

	Minus
	Plus
	Mul
	Rem
	Quo
	Inc
	Dec
	Dot
	LParen
	RParen
	Comma
	SemiColon
	LBrace
	RBrace
	LBrack
	RBrack
	Less
	Greater
	LessEq
	GreaterEq
	Equal
	NotEqual
	TEqual // stands for triple equal x_x
	NotTEqual
	LShift
	RShift
	RShiftZero // Right Shift with zero filling, yay JS
	And
	Or
	Xor
	Not
	LNot
	LAnd
	LOr
	Colon
	Assign
	AddAssign
	SubAssign
	MulAssign
	RemAssign
	QuoAssign
	LShiftAssign
	RShiftAssign
	RShiftZeroAssign
	AndAssign
	OrAssign
	XorAssign
	Ternary

	Ident

	Null
	Undefined

	Break
	Case
	Catch
	Continue
	Debugger
	Default
	Delete
	Do
	Else
	Finally
	For
	Function
	If
	In
	InstanceOf
	New
	Return
	Switch
	This
	Throw
	Try
	TypeOf
	Var
	Void
	While
	With

	EOF
)

func (Type) String

func (t Type) String() string

Jump to

Keyboard shortcuts

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