Skip to main content

embedded_rhai_interpreter_bytes

Function embedded_rhai_interpreter_bytes 

Source
pub fn embedded_rhai_interpreter_bytes() -> &'static [u8] 
Expand description

The shared Rhai interpreter’s compiled bytes, embedded at compile time.

This is a checked-in binary asset (assets/rhai-interpreter.wasm), not built dynamically as part of an ordinary cargo build --workspaceinclude_bytes! is resolved by rustc while compiling this crate, so the file must already exist on disk before this crate compiles, and Cargo has no built-in way to cross-compile a sibling workspace member to wasm32-unknown-unknown first as part of building this one natively. Regenerate it with scripts/rebuild-rhai-interpreter.sh whenever blocks/rhai-interpreter’s source changes, and commit the result — CI independently checks the asset hasn’t drifted (see .github/workflows/ci.yml).