Skip to main content

call_value

Function call_value 

Source
pub fn call_value(ctx: &EvalContext, func: &Value, args: &[Value]) -> EvalResult
Expand description

Call a function value with already-evaluated arguments. This is the public API for stdlib functions that need to invoke callbacks.

For lambdas, this delegates to apply_lambda + a trampoline loop so that subsequent evaluation happens iteratively rather than adding Rust stack frames. This is critical for WASM where the call stack is limited (~5 MB).