state package:effectful-core
Apply the function to the current state and return a value.
Apply the function to the current state and return a value.
Note: this function gets an exclusive access to the state for
its duration.
Provide access to a mutable value of type s.
Provide access to a strict (WHNF), thread local, mutable value of type
s.
Provide access to a strict (WHNF), shared, mutable value of type
s.
Apply the function to the current representation of the effect and
return a value.
Apply the monadic function to the current representation of the effect
and return a value.
Modify the data type in the environment and return a value (in place).
Apply the monadic function to the current state and return a value.
Apply the monadic function to the current state and return a value.
Note: this function gets an exclusive access to the state for
its duration.
Describes the behaviour of a thread when an asynchronous exception is
received.
Run the
State effect with the given initial state and return
the final value, discarding the final state.
Run the
State effect with the given initial state and return
the final state, discarding the final value.
Run the
State effect with the given initial state and return
the final value along with the final state.