Documentation

Index

Constants

View Source
const (
	L = 0
	R = 1
)

Variables

View Source
var Ops = map[string]*Operator{}

Functions

func IsOperator

func IsOperator(str string) bool

func Register

func Register(op *Operator)

Types

type Operator

type Operator struct {
	Name          string
	Precedence    int
	Associativity int
	Args          int
	Operation     func(args []float64) float64
}

func FindOperatorFromString

func FindOperatorFromString(str string) *Operator

Directories

Path Synopsis