Hi Mark,
The state transformer approach seems to have
advantageous in that it provides a framework for
building new monads from old, and accessing the
components. One disadvantage is that it lacks
symmetry in that one monad is arbitrarily chosen
to sit inside the other.
You may want to read "comp
Am Donnerstag, 8. Januar 2004 03:20 schrieben Sie:
> [...]
> Thanks for your informative reply.
You're welcome.
> [...]
> One disadvantage is that it lacks symmetry in that one monad is arbitrarily
> chosen to sit inside the other.
Yes, I see this as a disadvantage, too.
> I found another app
Hi Wolfgang,
Thanks for your informative reply. At first I didn't
understand it, but a search on "StateT" lead me to the
paper "Monad Transformers and Modular Interpreters" by
Liang, Hudak and Jones, which clarified some of the
ideas for me.
The state transformer approach seems to have
advantage
Hello,
your problem can be solved with StateT:
(warning: untested code)
First we want to execute two independent state threads:
start1 :: Monad m => StateT Int m startOutput1
start1 =
start2 :: Monad m => StateT Bool m startOutput2
start2 =
After this there is a part where we
Hi,
I am still learning about monads. I have a problem
in mind and am wondering whether state monads are
able to solve it. The difficulty is that it would
necessitate the interaction of two state threads
and I'm not sure whether Haskell state monads
allow this. Let me explain what I'm getting a