FunctionVars returns a FunctionActivation combining the variable bindings from `vars` with the late-bound function implementations from `funcs`. FunctionVars support late-bound function definitions where the function behavior depends on the context of the evaluation. This can only be accomplished by
(vars any, funcs map[string]LateBoundFunction)
| 159 | // input. For example, a function comparing a validity window `valid_until(t)` could be implemented as |
| 160 | // a late-bound function closed over a fixed timestamp value. |
| 161 | func FunctionVars(vars any, funcs map[string]LateBoundFunction) (FunctionActivation, error) { |
| 162 | return interpreter.NewFunctionActivation(vars, funcs) |
| 163 | } |
| 164 | |
| 165 | // AttributePattern returns an AttributePattern that matches a top-level variable. The pattern is |
| 166 | // mutable, and its methods support the specification of one or more qualifier patterns. |