<html>
<head>
<meta http-equiv="content-type" content="text/html;
charset=ISO-8859-1">
</head>
<body bgcolor="#FFFFFF" text="#000000">
Hi cafe,<br>
<br>
For a while now, I've been wondering why the 'let' keyword in a do
block isn't optional. So instead of<br>
<br>
<font face="Courier New, Courier, monospace">do ...<br>
let x = exp1<br>
y = exp2<br>
z <- exp3<br>
...<br>
</font> <br>
you could simply write<br>
<br>
<font face="Courier New, Courier, monospace">do ...<br>
x = exp1<br>
y = exp2<br>
z <- exp3 <br>
...<br>
</font><br>
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. <br>
<br>
The above probably also holds for list/monad comprehensions, but the
explicit let has never really bothered me there.<br>
<br>
Cheers,<br>
Martijn Schrage -- Oblomov Systems (<a class="moz-txt-link-freetext"
href="http://www.oblomov.com">http://www.oblomov.com</a>)
</body>
</html>