[Haskell-cafe] Parse error

VoidPrayer voidprayer at gmail.com
Sun Jan 17 05:10:32 EST 2010


let ...
in ...

I guess GHC is finding where "in" is.

在 2010年 1月 17日 星期日 18:05:47,Andrew Coppin 寫道:
> Is there a specific reason why GHC consistently refuses to accept the
> following perfectly reasonable code snippet?
> 
> main = do
>   putStrLn "Line 1"
>   putStrLn "Line 2"
> 
>   let xs = do
>     x <- [1..10]
>     y <- [1..10]
>     return (x+y)
> 
>   print xs
> 
> No matter which way I rearrange this, it *insists* that there's a parse
> error. This is very frustrating, given that it's utterly clear what I
> want...
> 
> _______________________________________________
> 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