[Haskell-cafe] Re: Parse error

VoidPrayer voidprayer at gmail.com
Sun Jan 17 09:32:55 EST 2010


Oh, I should know that. Thank you.

By the way, is it only valid when "let" only affects the one expression after 
that? I read "where vs let" in the HaskellWiki but all the examples are "let 
... in".

在 2010年 1月 17日 星期日 22:13:14,Maciej Piechotka 寫道:
> On Sun, 2010-01-17 at 18:10 +0800, VoidPrayer wrote:
> > let ...
> > in ...
> >
> > I guess GHC is finding where "in" is.
> 
> Except that:
> 
> main = do l <- getLine
>           let l' = lines l
>           print l'
> 
> Is perfectly valid without in. Similary:
> 
> something = proc (x, y) -> do x' <- someArrow -< x
>                               let z = x + y + x'
>                               returnA -< z
> 
> Regards
> 
> 
> _______________________________________________
> 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