pub fn protected_call(
cx: &mut Cx,
function: Value,
args: Args,
map_error: impl FnOnce(&mut Cx, Error) -> Result<Value>,
) -> Result<ProtectedOutcome>Expand description
Calls function and maps kernel errors into a returned protected outcome.
The kernel callable surface returns one value per call. The protected result stores successful values in a vector so language layers with multi-value returns can reuse the same outcome type at their boundary.