Whilst I have nothing against the change in syntax for recursive do aka

http://old.nabble.com/Update-on-GHC-6.12.1-td26103595.html

Instead of writing

  mdo
    a <- getChar
    b <- f c
    c <- g b
    putChar c
    return b

you would write

  do
    a <- getChar
    rec { b <- f c
          ; c <- g b }
    putChar c
    return b

it does spoil the nice layout - it would be nice to just be able to write (which does not parse)

  do rec
    a <- getChar
    b <- f c
    c <- g b
    putChar c
    return b

I don't particularly care that the only recursive statements are #2,#3 - I just want my nice neat layout back. I have just spent an inordinate amount of time updating code when if the parser recognised "do rec" as a recursive group it would have been a drop in replacement and taken me one tenth of the time.

Why can't we have this?

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

Reply via email to