On 3 May 2015 13:19, "Matt Rice" <[email protected]> wrote:
> if 'let y = 4 in y' is a parameter why do you consider it a 'top-level'
binding
> I believe only forms of
>
> let x = 3
> let y = 4
> in x + y
I don't really understand. My point is 'let' syntax is an expression (it
has a value) not a top level binding. If you want a program to evaluate to
a value you can have exactly one top level expression. The syntax usually
used for your example is:
let x = 3,
y = 4
in x + y
If you beta reduce the let, you are substituting 3 and 4 for x and y in the
'in' expression.
Starting with:
let x = 3 in x
let y = 4 in y
After reduction we get:
3
4
Which is an invalid expression.
I think the top level should be a single expression which could be a single
let declaring multiple variables or just (3 + 4).
Keean.
_______________________________________________
bitc-dev mailing list
[email protected]
http://www.coyotos.org/mailman/listinfo/bitc-dev