#7157: 'let' keyword optional in do notation ------------------------------+--------------------------------------------- Reporter: Oblosys | Owner: Type: feature request | Status: new Priority: normal | Component: Compiler Version: 7.6.1-rc1 | Keywords: Os: Unknown/Multiple | Architecture: Unknown/Multiple Failure: None/Unknown | Testcase: Blockedby: | Blocking: Related: | ------------------------------+--------------------------------------------- Would it be possible to make the 'let' keyword in a do block optional? So instead of
{{{ do ... let x = exp1 y = exp2 z <- exp3 ... }}} you could simply write {{{ do ... x = exp1 y = exp2 z <- exp3 ... }}} Where each sequence of let-less bindings is put in a separate binding group. I'm no parsing wizard, but I couldn't come up with any situations in which this would cause ambiguity. To me, the let-less version is easier on the eyes, more consistent with <- bindings, and also makes it less of a hassle to move stuff around. The above probably also holds for list/monad comprehensions, but the explicit let has never really bothered me there. I've also posted the idea on Haskell cafe: [http://www.mail-archive.com/haskell-cafe@haskell.org/msg100541.html] -- Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/7157> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler _______________________________________________ Glasgow-haskell-bugs mailing list Glasgow-haskell-bugs@haskell.org http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs