Docs

inline

Source: crates/lvcs/src/runtime/inline.rs.

/// A machine run inside its owner's task (the daemon shell, row 211).
///
/// [`step`](Self::step) journals each event as `id` after the machine
/// processed it and before the owner applies any returned output, in the
/// driver's format, so replay treats an inline machine like a spawned one.
/// The owner applies the outputs in emit order in the same turn.
pub(crate) struct Inline<M, E, O> {
    /// The machine.
    machine: M,
    /// What the runtime needs of it.
    hooks: Hooks<M, O>,
    /// Its journal identity.
    id: ActorId,
    /// Where its entries go.
    journal: Writer,
    /// The `actor` span, with this machine's `actor_kind`.
    span: Span,
    /// The event type it is stepped with.
    event: PhantomData<fn(E)>,
}