std.effect.st
Modules
std.effect.st.string |
Implementation of the st.State
effect
Types
The State
effect enables the use of mutable state. By branding the state with s
the mutable
values are prevented from escaping the monad.
Values
#[inline(never)]
let send_state f : forall a r . forall s . State s r a -> Eff [| st : State s | r |] a
Creates a new mutable reference that contains a
.
Reads the values stored in the reference.
Writes a new value into the reference.
Eliminates the State
effect