expr.go 391 字节
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
package restruct

import (
	"github.com/go-restruct/restruct/expr"
)

var (
	expressionsEnabled = false
	stdLibResolver     = expr.NewMapResolver(exprStdLib)
)

// EnableExprBeta enables you to use restruct expr while it is still in beta.
// Use at your own risk. Functionality may change in unforeseen, incompatible
// ways at any time.
func EnableExprBeta() {
	expressionsEnabled = true
}