Stepping allows the user to observe the evaluation of an expression one reduction step at a time. When Donkey is in step mode, the current state of the evaluation process is displayed in the evaluation area.
While stepping, the user can select a different block, perform evaluations, and later return to the original block to finish the stepping process. Note that an arbitrary number of blocks may be independently stepped through at the same time.
While you are stepping and unstepping through history, you are only seeing snapshots of what you have seen before. Consequently, you cannot perform advanced stepping techniques on these expressions. The exception is that you can use the Breakpoints menu (Section 4.4). This will resume normal stepping at the current point, and you can use the advanced stepping features.
If pressed, during stepping, Step All steps completely through the selected subexpression and replaces it by its value. This allows you to quickly step through subexpressions in which you are not interested.
One may only use Step All for subexpressions that are ready for evaluation . That is, they contain the next subexpression to be reduced. This restricts the user from evaluating a subexpression that may not be evaluated in the normal course of stepping.
For example, in the expression:
(if (= 2 (+ 1 1))
(+ 2 2)
(+ 3 3))
The next subexpression to be reduced is so
(+ 1 1), (= 2 (+ 1 1)), or the entire expression
can be evaluated but (+ 1 1) and (+ 2 2) cannot
since which of these will be evaluated depends on the value of the
(unevaluated) condition.(+ 3 3)