Skip to main content

eval

Function eval 

Source
pub fn eval<D>(
    node: &Node,
    ctx: Value,
    dispatcher: &D,
) -> Result<Value, EvalError>
where D: Dispatcher,
Expand description

Legacy Value-passing sync evaluator — backward compat wrapper around eval_with_storage + MemoryCtx. Value を所有権で受け取り、 内部で MemoryCtx::new(ctx) を使って storage 版に委譲、 終了後の snapshot を返す。

既存 caller (= dynamic injection を要求しない、 1-shot pure eval 用途) は 引き続きこの API で OK。 動的注入が要る場合は eval_with_storage を直接 呼ぶ。

Returns the updated context (= ctx with Step.out path written for each step traversed).