Call Build Arguments Rule: Values
When the state is "call_build_args" and the "Values" list is not empty, then pop the first element from the "Values" list.
if the following are true:
- expression state at time t = "call_build_args"
- Parameters List at time t = [ var, frest ]
- Argument Values at time t = [ value, vrest ]
then Argument Values at time (t + 1) = vrest
When the state is "call_build_args," elements are popped from the values list and used as values in the temporary variable map.
For example,
if the following are true:
- expression state at time 11 = "call_build_args"
- Parameters List at time 11 = [ x, [ ] ]
- Argument Values at time 11 = [ 5, [ ] ]
then Argument Values at time (11 + 1) = [ ]
Try stepping through the simulator to see LW Python pop 5 from the "Values" list.
Code Editor
LW Python State
Current Line | 1 | Current Tab | 0 | Time | 0 |
LW Python Simulator
Comments
Please log in to add comments