{"modulePath":"github.com/expr-lang/expr","version":"v1.18.1","isLatest":true,"isStandardLibrary":false,"goos":"all","goarch":"all","docs":"# package runtime\n\n## Functions\n\n```go\nfunc Add(a, b interface{}) interface{}\n```\n\n```go\nfunc Divide(a, b interface{}) float64\n```\n\n```go\nfunc Equal(a, b interface{}) bool\n```\n\n```go\nfunc Exponent(a, b any) float64\n```\n\n```go\nfunc Fetch(from, i any) any\n```\n\n```go\nfunc FetchField(from any, field *Field) any\n```\n\n```go\nfunc FetchFromEmbeddedInterfaces(v reflect.Value, fieldName string) (any, bool)\n```\nFetchFromEmbeddedInterfaces looks up fieldName on the concrete types held by anonymous (embedded) interface fields of the struct value v, recursing through embedded structs to reach further embedded interfaces. It is shared by Fetch and the builtin get() so that both resolve such fields consistently.\n\n```go\nfunc FetchMethod(from any, method *Method) any\n```\n\n```go\nfunc In(needle any, array any) bool\n```\n\n```go\nfunc IsNil(v any) bool\n```\n\n```go\nfunc Len(a any) int\n```\n\n```go\nfunc Less(a, b interface{}) bool\n```\n\n```go\nfunc LessOrEqual(a, b interface{}) bool\n```\n\n```go\nfunc MakeRange(min, max int) []int\n```\n\n```go\nfunc Modulo(a, b interface{}) int\n```\n\n```go\nfunc More(a, b interface{}) bool\n```\n\n```go\nfunc MoreOrEqual(a, b interface{}) bool\n```\n\n```go\nfunc Multiply(a, b interface{}) interface{}\n```\n\n```go\nfunc Negate(i any) any\n```\n\n```go\nfunc Slice(array, from, to any) any\n```\n\n```go\nfunc Subtract(a, b interface{}) interface{}\n```\n\n```go\nfunc ToBool(a any) bool\n```\n\n```go\nfunc ToFloat64(a any) float64\n```\n\n```go\nfunc ToInt(a any) int\n```\n\n```go\nfunc ToInt64(a any) int64\n```\n\n## Types\n\n```go\ntype Field struct {\n\tIndex []int\n\tPath  []string\n}\n```\n\n```go\ntype Method struct {\n\tIndex int\n\tName  string\n}\n```\n\n```go\ntype Sort struct {\n\tDesc  bool\n\tArray []any\n}\n```\n\n```go\nfunc (s *Sort) Len() int\n```\n\n```go\nfunc (s *Sort) Less(i, j int) bool\n```\n\n```go\nfunc (s *Sort) Swap(i, j int)\n```\n\n```go\ntype SortBy struct {\n\tDesc   bool\n\tArray  []any\n\tValues []any\n}\n```\n\n```go\nfunc (s *SortBy) Len() int\n```\n\n```go\nfunc (s *SortBy) Less(i, j int) bool\n```\n\n```go\nfunc (s *SortBy) Swap(i, j int)\n```\n\n","path":"github.com/expr-lang/expr/vm/runtime","name":"runtime","synopsis":"","isRedistributable":true}
