I am referring to the rule for function calls. I propose the following (thanks to my students):
===
-
in f(a1 , ... an) the "n" should an "m"
-
the gamma in "gamma.x1" on the left just above the horizontal line should be a gammaₘ
-
the gamma′ should be a gamma′.delta (the delta is needed to make work the below)
-
the gammaₘ on the right below the horizontal bar should be a gamma′
===
Wrt to item 2), the book says that it does not matter whether one would put gamma or gammaₘ . But if we take the following C program
int x = 10; int f (int y) { return ++x; }
then calling f(++x) modifies the global variable x to 12. This is not compatible with running { return ++x; } in context gamma (which has x:=10) but requires that { return ++x; } is run in context gammaₘ (which has x:=11).
I am referring to the rule for function calls. I propose the following (thanks to my students):
===
in f(a1 , ... an) the "n" should an "m"
the gamma in "gamma.x1" on the left just above the horizontal line should be a gammaₘ
the gamma′ should be a gamma′.delta (the delta is needed to make work the below)
the gammaₘ on the right below the horizontal bar should be a gamma′
===
Wrt to item 2), the book says that it does not matter whether one would put gamma or gammaₘ . But if we take the following C program
then calling
f(++x)modifies the global variablexto12. This is not compatible with running{ return ++x; }in context gamma (which hasx:=10) but requires that{ return ++x; }is run in context gammaₘ (which hasx:=11).