Skip to main content

Crate sim_lib_sequence

Crate sim_lib_sequence 

Source
Expand description

Sequence behavior for the SIM runtime: lazy, persistent, and transducers.

The kernel defines the operation and object contracts; this crate supplies the concrete sequence organ (lazy sequences, persistent vectors/maps/sets, and transducer pipelines).

Structs§

LazySequence
On-demand sequence object driven by a SequenceProducer.
PersistentSet
Immutable, shareable set object holding canonically distinct elements.
PersistentVector
Immutable, shareable vector object backed by a shared slice.
ProfileSequence
Sequence object that tags an inner sequence with a language profile.
TransducerPipeline
An ordered chain of TransducerSteps applied per element in one pass.

Enums§

TransducerStep
A single stage of a TransducerPipeline.

Functions§

filter_sequence
Return a lazy sequence that keeps elements of source passing predicate.
for_each_sequence
Apply visitor to each element of source for its effect.
force_sequence_bounded
Drive a sequence to completion, refusing to exceed max elements.
lazy_sequence_value
Wrap a SequenceProducer as a runtime sequence Value.
map_sequence
Return a lazy sequence that maps each element of source.
persistent_list
Construct an immutable list Value from the given elements.
persistent_list_push
Return a new list with item appended; the input list is unchanged.
persistent_map
Construct an immutable map (table) Value from key/value entries.
persistent_map_assoc
Return a new map with key bound to value; the input map is unchanged.
persistent_set
Construct a PersistentSet as a runtime Value, deduplicating elements.
persistent_set_insert
Return a new set with item inserted if canonically absent; input unchanged.
persistent_vector
Construct a PersistentVector as a runtime Value.
persistent_vector_push
Return a new vector with item appended; the input vector is unchanged.
publish_sequence_organ_claims
Publish the sequence organ and its operation keys into the claim store.
publish_sequence_organ_claims_for_lib
Publish the sequence organ claims as part of a loaded lib receipt.
reduce_sequence
Fold source into a single value with reducer, starting from init.
sequence_filter_op_key
Operation key for sequence filtering.
sequence_for_op_key
Operation key for sequence iteration (for-each).
sequence_for_profile
Tag a sequence Value with a language profile via ProfileSequence.
sequence_from_list_value
Adapt a list Value into a sequence Value.
sequence_lazy_op_key
Operation key for lazy sequence construction.
sequence_map_op_key
Operation key for sequence mapping.
sequence_op_keys
All operation keys the sequence organ advertises.
sequence_organ_symbol
Symbol naming the sequence organ as a claim subject.
sequence_persistent_op_key
Operation key for persistent sequence construction.
sequence_reduce_op_key
Operation key for sequence reduction.
sequence_transduce_op_key
Operation key for transducer-driven sequence pipelines.
transduce
Stream source through pipeline and fold survivors into a single value.

Type Aliases§

SequenceProducer
Element generator backing a LazySequence.