Skip to main content

Module crossinterp

Module crossinterp 

Source
Expand description

Cross-interpreter object sharing and exception snapshots (XI data).

Interpreters do not share PyObject graphs. Shareable values are converted to an interpreter-neutral payload and rebuilt in the destination.

Structs§

ExcInfo
Snapshot of an exception that can be rebuilt in another interpreter.
PickledData
Pickled bytes and the originating script, without interpreter-owned references.
SharedQueueId
A queue reference held by cross-interpreter data. Cloning takes another reference and dropping releases one.

Enums§

Fallback
xidata_fallback_t: what to do with an object that has no XI data support.
SharedValue
Interpreter-neutral payload that can be materialized in any interpreter sharing the process-wide crate::Context.
UnboundOp
Unbound-item ops (UNBOUND_REMOVE / UNBOUND_ERROR / UNBOUND_REPLACE).

Functions§

apply_shared_ns
is_running
is_shareable
Exact-type shareable check used by _interpreters.is_shareable.
script_code
Extract a script code object from source text / function / code object.
utf8_key
Encode a namespace key as UTF-8, rejecting non-strings and lone surrogates.
verify_script
verify_script: a script takes no arguments and returns only None.