S. Doaitse Swierstra schrieb:
[..]
\begin{code}
main = do
if True then putStrLn 1;
else putStrLn 2
\end{code}
This does also not work with hugs (; at the end)
This does not work since now you have two ;'s; one because you wrote
one and one because you did not indent the else. Allowing
Hi,
seeing Haskell 2010 and
http://hackage.haskell.org/trac/haskell-prime/wiki/DoAndIfThenElse
saying:
Compiler support ¶
GHC full (no flag)
I wonder why I still get a parse error (possibly incorrect
indentation) for:
\begin{code}
main = do
if True then putStrLn 1
else putStrLn 2
\end
On Thu, Nov 26, 2009 at 10:29 AM, Christian Maeder christian.mae...@dfki.de
wrote:
I wonder why I still get a parse error (possibly incorrect
indentation) for:
\begin{code}
main = do
if True then putStrLn 1
else putStrLn 2
\end{code}
Isn't the proposal about :
\begin{code}
main = do
Hi Christian,
On Thu, Nov 26, 2009 at 10:29:10AM +0100, Christian Maeder wrote:
seeing Haskell 2010 and
http://hackage.haskell.org/trac/haskell-prime/wiki/DoAndIfThenElse
saying:
Compiler support ¶
GHC full (no flag)
I wonder why I still get a parse error (possibly incorrect
David Virebayre schrieb:
Isn't the proposal about :
\begin{code}
main = do
if True then putStrLn 1
;else putStrLn 2
\end{code}
This should go through, too, but also does not for me according to
http://hackage.haskell.org/trac/haskell-prime/wiki/DoAndIfThenElse
cite
Change the syntax