Skip to main content

Crate gust_runtime

Crate gust_runtime 

Source
Expand description

§Gust Runtime

The runtime support library for compiled Gust state machine programs.

When the Gust compiler generates Rust code from .gu source files, the generated code depends on this crate for core traits and utilities. Generated modules typically begin with use gust_runtime::prelude::*; to bring all necessary items into scope.

§What this crate provides

§Re-exports

The prelude also re-exports serde, serde_json, and thiserror so that generated code does not need to declare these as direct dependencies.

§Usage

You normally do not depend on this crate directly. Instead, the Gust compiler adds it to your generated code automatically. If you need to interact with generated machines from hand-written Rust, add the dependency to your Cargo.toml:

[dependencies]
gust-runtime = "0.1"

Modules§

prelude
Re-exports of the runtime traits and types that generated Gust code relies on. Generated .g.rs files use gust_runtime::prelude::*; to bring Machine, Supervisor, Envelope, RestartStrategy, and third-party re-exports (serde, serde_json, thiserror) into scope.