[Haskell-cafe] Different semantics in "identical" do statement?
Ross Mellgren
rmm-haskell at z.odi.ac
Fri Oct 9 17:53:39 EDT 2009
In what Monad?
-Ross
On Oct 9, 2009, at 5:43 PM, staafmeister wrote:
>
>
> In my program
>
> do
> x <- do
> blah <- someFunc
> return blah
> return $ Constructor x
>
> behaves differently from
> do
> blah <- someFunc
> return $ Constructor blah
>
> where the dots are identical. I would think that these programs should
> behave identically, by the monad laws.
> The result of my program is that the second gives correct behaviour,
> while
> the first loops forever.
>
> Greetings,
> Gerben
> --
> View this message in context: http://www.nabble.com/Different-semantics-in-%22identical%22-do-statement--tp25828319p25828319.html
> Sent from the Haskell - Haskell-Cafe mailing list archive at Nabble.com
> .
>
> _______________________________________________
> Haskell-Cafe mailing list
> Haskell-Cafe at haskell.org
> http://www.haskell.org/mailman/listinfo/haskell-cafe
More information about the Haskell-Cafe
mailing list