Skip to main content

Module compile

Module compile 

Source
Expand description

The compiled chart: a validated IR flattened into dense tables for the step kernel.

States are numbered in document order with the <scxml> root at index ROOT; because the numbering is a pre-order walk, the descendants of a state occupy the contiguous index range i + 1 ..= last, so isDescendant is two comparisons. Ascending index order is entry order and descending index order is exit order. Every compound state (and the root) gets a synthesized default-entry transition resolved by crate::validate::resolve_initial, and transition domains are precomputed whenever they do not depend on history. The compiled chart is derived data and is never serialized; only the IR is.

Structs§

CState
A state in the compiled chart.
CTransition
A transition in the compiled chart.
CompiledChart
A validated chart flattened into tables for the step kernel.

Enums§

Domain
The transition domain, precomputed when it does not depend on history.

Constants§

ROOT
Index of the <scxml> root.

Type Aliases§

StateIdx
Dense index of a state; ROOT is the <scxml> element.
TransIdx
Dense index of a transition in CompiledChart::transitions.