Skip to content

Instantly share code, notes, and snippets.

@theqp
Created November 27, 2020 07:56
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save theqp/cd8c2a33e368e1267ae4278ccb5541ff to your computer and use it in GitHub Desktop.
Save theqp/cd8c2a33e368e1267ae4278ccb5541ff to your computer and use it in GitHub Desktop.
modify' :: Functor m => (s -> m s) -> StateT s m ()
modify' f = StateT (f >>> fmap ((),))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment