
1 Apr
2013
1 Apr
'13
12:49 p.m.
On Mon, Apr 1, 2013 at 9:32 AM, Richard Eisenberg
Normal "let": In a function (which does not use "do"), you can use "let" to make local variables. The word "in" separates the local variable declaration from the part of your function where you want to use that variable. Loosely translating from Haskell to C++:
Haskell:
let foo = bar in baz
C++:
/* insert correct type here */ foo = bar; baz
For the C++, I'd say
{ /* insert correct type here */ foo = bar; baz }
for let ... in, whereas let without in (only permitted in do notation) discards those braces.