So all the Xs would be in scope at s6. Important point.

Thanks,

Michael

--- On Tue, 8/10/10, Alex Stangl <[email protected]> wrote:

From: Alex Stangl <[email protected]>
Subject: Re: [Haskell-cafe] Couple of questions about *let* within *do*
To: "michael rice" <[email protected]>
Cc: "Tillmann Rendel" <[email protected]>, 
[email protected]
Date: Tuesday, August 10, 2010, 2:21 PM

On Tue, Aug 10, 2010 at 11:01:28AM -0700, michael rice wrote:
> Hi all,
> 
> Then,
> 
>   do s1
>      s2
>      let x1 = e1
>          x2 = e2
>      s3
>      s4
>      let x3 = e3
>          x4 = e4
>      s5
>      s6
> 
> becomes
> 
>   do s1
>      s2
>      let x1 = e1
>          x2 = e2 in do s3
>                        s4
>      let x3 = e3
>          x4 = e4 in do s5
>                        s6?

    do s1
       s2
       let x1 = e1
           x2 = e2
       in do s3
             s4
             let x3 = e3
                 x4 = e4
             in do s5
                   s6

HTH,

Alex



      
_______________________________________________
Haskell-Cafe mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/haskell-cafe

Reply via email to