4 Debugging Advice
When a new program does not behave correctly, use the runtime hooks in "sick.rkt" instead of guessing.
Useful starting points are:
SICK_DEBUG=1 to enable tracing,
SICK_DEBUG_LINES=... to restrict the trace to a few labels,
SICK_BREAK_LINES=... to stop before a line executes, and
SICK_BREAK_REPEAT=N to stop when the same control-flow state repeats.
For example, to focus on the loop controller in "pit/triangular.i":
SICK_DEBUG=1 \ |
SICK_DEBUG_LINES=1,3,4 \ |
racket pit/triangular.i |
The same workflow scales to larger programs such as "pit/sort.i" or "pit/unlambda.i".