[Haskell-cafe] Calling a State Monad recursively from within a let-block, via runState?
juan.casanova at ed.ac.uk
Fri Mar 13 23:00:42 UTC 2020
I do this relatively often. I see the State monad as a convenient way
to see the type (s -> (a,s)) that happens to have a monad instance.
When the best way to make use of it is to go in and out of monad
"mode", I do that.
Quoting David Banas <capn.freako at gmail.com> on Fri, 13 Mar 2020
> Can I call a State Monad recursively from within a let-block, via
> `runState`, or is that going way out of bounds?
> Haskell-Cafe mailing list
> To (un)subscribe, modify options or view archives go to:
> Only members subscribed via the mailman list are allowed to post.
The University of Edinburgh is a charitable body, registered in
Scotland, with registration number SC005336.
More information about the Haskell-Cafe