Provide access to a mutable value of type s.
Instances1DispatchOf
type DispatchOf (State s) = 'DynamicDefined in effectful-core-2.3.0.1 · Effectful.State.Dynamic
:: a typeCtrl KGHC 9.10.3 · lts/ghc-9.10.x · 248f8f0 · 2026-10-05
Moduleeffectful-core-2.3.0.1Haskell2010
The dynamically dispatched variant of the State effect.
Note: unless you plan to change interpretations at runtime, it's recommended to use one of the statically dispatched variants, i.e. Effectful.State.Static.Local or Effectful.State.Static.Shared.
Provide access to a mutable value of type s.
type DispatchOf (State s) = 'DynamicDefined in effectful-core-2.3.0.1 · Effectful.State.DynamicRun the State effect with the given initial state and return the final value along with the final state (via Effectful.State.Static.Local).
Run the State effect with the given initial state and return the final value, discarding the final state (via Effectful.State.Static.Local).
Run the State effect with the given initial state and return the final state, discarding the final value (via Effectful.State.Static.Local).
Fetch the current value of the state.
Set the current state to the given value.
Apply the function to the current state and return a value.
Apply the monadic function to the current state and return a value.