Skip to content

Frame v0.7.2

Choose a tag to compare

@walkie walkie released this 08 Dec 23:43
· 410 commits to main since this release

This release adds a new feature to the Rust backend: codegen.rust.features.thread_safe.

Generating Send- and Sync-compatible state machines

When the new thread_safe feature is enabled, Framec will generate a state machine that implements Rust's standard Send and Sync traits, as long as all of declared domain variables also implement these traits.

The feature is disabled by default.

Impact on the runtime interface

By far the biggest impact of the new thread_safe feature is on the runtime interface (see the Release Notes for v0.7.0 and v0.7.1), which has been split into two variants:

  • frame_runtime::sync, which is implemented by machines compiled with runtime_support=true and thread_safe=true

  • frame_runtime::unsync, which is implemented by machines compiled with runtime_support=true and thread_safe=false

Note that the treatment of environments in the sync runtime interface is less efficient than in the unsync variant, and the sync variant also requires that all domain variables implement Clone. These issues/limitations may be resolved in the future.