Dense, fork-local runtime state for SCI contexts.
Stable handles are assigned integer slots once per context lineage. A world stores slot values densely and a frozen fork copies that array while the source world is quiescent. Mutable primitives CAS only their own slot, so unrelated atoms never contend on a shared world root.
Dense, fork-local runtime state for SCI contexts. Stable handles are assigned integer slots once per context lineage. A world stores slot values densely and a frozen fork copies that array while the source world is quiescent. Mutable primitives CAS only their own slot, so unrelated atoms never contend on a shared world root.
(active-ctx captured)Use the currently evaluating descendant context for an interpreted closure. Unrelated SCI contexts cannot capture one another accidentally.
Use the currently evaluating descendant context for an interpreted closure. Unrelated SCI contexts cannot capture one another accidentally.
(attach-managed-owner! registry managed-index owner)Attach weak ownership after constructing a self-described handle. The owner is never retained strongly by the lineage registry.
Attach weak ownership after constructing a self-described handle. The owner is never retained strongly by the lineage registry.
(binding-scope)Return the currently executing world for dynamic-binding isolation. Nil denotes a host binding established outside managed SCI evaluation.
Return the currently executing world for dynamic-binding isolation. Nil denotes a host binding established outside managed SCI evaluation.
(call-with-context ctx f)Run f with ctx installed as both SCI's dynamic context and active world.
This is the host invocation boundary for interpreted values that outlive the
top-level evaluation which produced them.
Run `f` with `ctx` installed as both SCI's dynamic context and active world. This is the host invocation boundary for interpreted values that outlive the top-level evaluation which produced them.
(call-with-var-context handle f)Run f in the active related world for handle, or in the Var's stable
home world when invoked directly by the host. Shared built-in Vars have no
home and retain their direct compatibility behavior.
Run `f` in the active related world for `handle`, or in the Var's stable home world when invoked directly by the host. Shared built-in Vars have no home and retain their direct compatibility behavior.
(-mark-world-tracked! handle home-ctx)(-world-home-ctx handle)(-world-tracked? handle)(managed-assoc! home registry slot k value)Associate one key in a managed persistent-map slot without the generic callback/validation path. Used by mutable SCI deftype fields.
Associate one key in a managed persistent-map slot without the generic callback/validation path. Used by mutable SCI deftype fields.
(managed-compare-and-set! home registry slot expected new validate! notify!)(managed-compare-and-set! home
registry
slot
expected
new
validate!
notify!
coordination)(managed-compare-and-set! home
registry
slot
expected
new
validate!
notify!
coordination
validation-current?)(managed-reset! home registry slot new validate! notify!)(managed-reset! home registry slot new validate! notify! coordination)(managed-reset! home
registry
slot
new
validate!
notify!
coordination
validation-current?)(managed-swap! home registry slot f args validate! notify!)(managed-swap! home registry slot f args validate! notify! coordination)(managed-swap! home
registry
slot
f
args
validate!
notify!
coordination
validation-current?)CAS a directly described slot. The logical fallback represents a slot allocated in another branch but not yet realized in the selected world.
CAS a directly described slot. The logical fallback represents a slot allocated in another branch but not yet realized in the selected world.
(managed-update-control-with-value! home
registry
value-slot
control-slot
coordination
validate-value!
update-control)Atomically validate the selected value and update a related control slot.
coordination must be the same stable handle used by value commits.
Atomically validate the selected value and update a related control slot. `coordination` must be the same stable handle used by value commits.
(managed-value home registry slot)Read a self-described managed slot in the active related world, falling back to the owner's creation world outside managed evaluation.
Read a self-described managed slot in the active related world, falling back to the owner's creation world outside managed evaluation.
(managed-value-in world home slot)Read a managed slot from an already selected world.
Read a managed slot from an already selected world.
(register-managed! kind values fork-indexes)Allocate dense slots whose owner carries the returned descriptor directly.
Managed descriptors contain no owner reference, so an unreachable SCI ref is
not retained by the lineage registry. fork-indexes names values that need
host Forkable/:fork-fn processing when a child world is copied.
Allocate dense slots whose owner carries the returned descriptor directly. Managed descriptors contain no owner reference, so an unreachable SCI ref is not retained by the lineage registry. `fork-indexes` names values that need host `Forkable`/`:fork-fn` processing when a child world is copied.
(slot-of world handle)Return the value slot assigned to handle, or nil when it is not registered
in this lineage. Intended for analyzer-time resolution.
Return the value slot assigned to `handle`, or nil when it is not registered in this lineage. Intended for analyzer-time resolution.
(swap-value! handle f args validate! notify!)Atomically update one tracked slot. Unrelated SCI atoms do not contend and
cannot cause f to be retried.
Atomically update one tracked slot. Unrelated SCI atoms do not contend and cannot cause `f` to be retried.
(var-value handle fallback)Primary contexts retain their direct Var realization. Descendants resolve the stable Var handle through its dense lineage slot.
Primary contexts retain their direct Var realization. Descendants resolve the stable Var handle through its dense lineage slot.
(var-value-at slot fallback)Read a Var through a slot already resolved by the analyzer.
Read a Var through a slot already resolved by the analyzer.
(with-active-world ctx f)Run f with the context's world installed. On the JVM evaluations take a
shared gate permit; a fork takes the exclusive permit and therefore observes
a quiescent source world without adding locks to individual reads.
Run `f` with the context's world installed. On the JVM evaluations take a shared gate permit; a fork takes the exclusive permit and therefore observes a quiescent source world without adding locks to individual reads.
cljdoc builds & hosts documentation for Clojure/Script libraries
| Ctrl+k | Jump to recent docs |
| ← | Move to previous article |
| → | Move to next article |
| Ctrl+/ | Jump to the search field |