#[unsafe(no_mangle)]pub unsafe extern "C" fn nemo_flow_scope_stack_set_thread(
stack: *const FfiScopeStack,
) -> NemoFlowStatusExpand description
Bind an isolated scope stack to the current OS thread.
After this call, all NeMo Flow scope operations on the current thread
(e.g. nemo_flow_push_scope, nemo_flow_get_handle) will use the
given scope stack. This is typically used from Go goroutines that have
called runtime.LockOSThread().
The FfiScopeStack is not consumed — the caller retains ownership
and must still free it when done.
§Parameters
stack: Scope stack to bind to the current OS thread.
§Returns
- Returns
NemoFlowStatus::Okwhen the thread-local scope stack was updated successfully. - Returns
NemoFlowStatus::NullPointerwhenstackis null.
§Safety
stack must be a valid, non-null FfiScopeStack pointer.