Rellum Rellum

S0065: committed state value moved in effect body

Generated from rellum-diagnostics/src/db.rs.

Explanation

~ state values are committed to globals at the end of Advance and persist across ticks. They are owned by the tick runtime, not by the effect body. Moving a committed state value in an effect body would leave the state slot in an invalid state for the next tick's Observe phase.

Common causes

Canonical fixes

Before:

send!(socket, encode(history))

After:

send!(socket, encode(share(history)))

Code example

send!(socket, encode(history))