constant

package
v1.17.8 Latest Latest
Warning

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

Go to latest
Published: Jul 24, 2022 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Definition = map[string]map[string]interface{}{
	"MATH": {
		"E":       math.E,
		"PI":      math.Pi,
		"PHI":     math.Phi,
		"SQRT2":   math.Sqrt2,
		"SQRTE":   math.SqrtE,
		"SQRTPI":  math.SqrtPi,
		"SQRTPHI": math.SqrtPhi,
		"LN2":     math.Ln2,
		"LOG2E":   math.Log2E,
		"LN10":    math.Ln10,
		"LOG10E":  math.Log10E,
	},
	"FLOAT": {
		"MAX":              math.MaxFloat64,
		"SMALLEST_NONZERO": math.SmallestNonzeroFloat64,
	},
	"INTEGER": {
		"MAX": int64(math.MaxInt64),
		"MIN": int64(math.MinInt64),
	},
}
View Source
var ErrInvalidType = errors.New("invalid constant type")
View Source
var ErrUndefined = errors.New("constant is not defined")

Functions

func ConvertConstantToPrivamryValue

func ConvertConstantToPrivamryValue(c interface{}) (value.Primary, error)

func Count

func Count() int

func Get

func Get(expr parser.Constant) (value.Primary, error)

Types

This section is empty.

Jump to

Keyboard shortcuts

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