ATM a field access x.y is simply rewritten to y(x) and also y does not need to be a field, but may be resolved from scope, for instance let y = ...; x.y would resolve the field as the let-bound y. This can lead to the hilarious situation where let thing = ...; thing.thing is translated to BindState (Var "thing") (Var "thing") which is obvious nonsense.
ATM a field access
x.y
is simply rewritten toy(x)
and alsoy
does not need to be a field, but may be resolved from scope, for instancelet y = ...; x.y
would resolve the field as the let-boundy
. This can lead to the hilarious situation wherelet thing = ...; thing.thing
is translated toBindState (Var "thing") (Var "thing")
which is obvious nonsense.