Go backward to Stack-Managed Storage Go up to Top Go forward to The Meaning of Identifiers |
D: Declaration -> Environment -> Store -> (Environment × Poststore)
D[[var I]] =
lambda e.lambda s. let (l,p) = (allocate-locn s)
in ((updateenv [[I]] inLocation(l) e), p)
D[[D1; D2]] =
lambda e.lambda s. let (e',p) = (D[[D1]]e s)
in (check D[[D2]]e')(p)
K[[begin D;C end]] = lambda e.lambda s.
let l = mark-locn in
let (e',p) = D[[D]]e s in
let p' = (check (C[[C]]e'))(p)
in (check (deallocate-locns l))(p')
Environment beckomes run-time object because binding of location values to identifiers depends on run-time store.