I had some success with the Stepper.

(define (test x)
        (car x)
        (cdr x))
(test ‘(a b c))

Place cursor at the beginning of (test ‘(a b c))

Then:
M-x step-defun

Then:
press space to step

Seems like a useful feature!

Nick
        
> On Apr 3, 2020, at 8:18 AM, Nicholas Papadonis <[email protected]> 
> wrote:
> 
> I opened runtime/ystep.scm and edwin/eystep.scm and used eval-current-buffer. 
>  There are many unbound variables and the debugger is opened.  Also, what 
> function should be applied to start stepping.
> 
> I’m in the middle of SICP so any guidance on using this interface is 
> appreciated.
> 
> Thanks
> 
>> On Mar 27, 2020, at 3:56 AM, Chris Hanson <[email protected] 
>> <mailto:[email protected]>> wrote:
>> 
>> 
>> The debugger can’t examine what will happen in the future, because that 
>> hasn’t happened yet.
>> 
>> If you want to move forward, you have several options:
>> Resume the program using one of the restarts that are shown when you stop.
>> Evaluate subexpressions in the debugger to see what they do.
>> Run the stepper to evaluate expressions one step at a time.
>> The stepper isn’t documented but the source files are runtime/ystep.scm for 
>> the basic stepper and edwin/eystep.scm for the Edwin stepper interface.  
>> Caveats: the stepper works only for interpreted code, not compiled code, so 
>> you can’t step into compiled code to see what it’s doing.
>> On Mar 26, 2020, 5:20 PM -0700, Nicholas Papadonis 
>> <[email protected] <mailto:[email protected]>>, wrote:
>>> When I insert (bkpt) in the code it launches the debugger, it appears the 
>>> debugger can move backwards in subproblems/reductions, however cannot move 
>>> forward past the (bkpt).
>>> 
>>> Is there a way to evaluate expressions forward past the break point?
>>> 
>>> I did not see an option in the debugger help. 
>>> 
>>> Thanks
> 

Reply via email to