[Haskell-cafe] questions on lazy pattern, StateT monad
wolfgang at jeltsch.net
Thu Nov 24 05:49:17 EST 2005
Am Mittwoch, 23. November 2005 20:42 schrieb Wolfgang Jeltsch:
> Am Mittwoch, 23. November 2005 19:02 schrieb Fan Wu:
> > But it is still not clear to me why lazy pattern is used here. Any ideas?
> Let's discuss this for State instead of StateT because this makes the
> discussion easier.
Oops, I've answered a question you didn't ask. I haven't looked at your
message carefully enough and thought that you were refering to the
implementation of (>>=) while in fact you were refering to the implementation
of mplus. But I think the reasons behind lazy pattern usage in the mplus
implementation are similar to those behind lazy pattern usage in the (>>=)
More information about the Haskell-Cafe