patch_seq_weave

Function patch_seq_weave 

Source
#[unsafe(no_mangle)]
pub unsafe extern "C" fn patch_seq_weave(stack: Stack) -> Stack
Expand description

Create a woven strand from a quotation

Stack effect: ( Quotation – WeaveHandle )

Creates a weave from the quotation. The weave is initially suspended, waiting to be resumed with the first value. The quotation will receive a WeaveCtx on its stack that it must pass to yield operations.

Returns a WeaveHandle that the caller uses with strand.resume.

§Error Handling

This function never panics (panicking in extern “C” is UB). On fatal error (null stack, null function pointer, type mismatch), it prints an error and aborts the process.

§Safety

Stack must have a Quotation on top