wrongusername
wrongusername

Reputation: 18918

Evaluating expressions in SLIME while using STEP

I am using SLIME with SBCL. Normally in SBCL, I can do (step (call-some-function 1 2 3)) and I will be able to step through/into/out of each line of code, as well as executing arbitrary expressions of my own to see what the current state of certain variables are.

But if I try to do the same in the REPL in SLIME, I get:

Evaluating call:
  (CP-GET-ALL-PE-MATCHES-ANY-LENGTH SENT-ID)
With arguments:
  581869302


   [Condition of type STEP-FORM-CONDITION]

Restarts:
 0: [STEP-CONTINUE] Resume normal execution
 1: [STEP-OUT] Resume stepping after returning from this function
 2: [STEP-NEXT] Step over call
 3: [STEP-INTO] Step into call
 4: [ABORT] Exit debugger, returning to top level.

Backtrace:
  0: (call-some-function 1 2 3)
  ...

There doesn't seem to be any way to obtain the current value of sent-id, or to evaluate (nth 1 some-list).

Is this in fact the case, and if so, does that mean I will have to fire up a second instance of SBCL in the terminal, and step through the function at the same time as in SLIME in order to get this functionality?

Upvotes: 0

Views: 649

Answers (1)

ghollisjr
ghollisjr

Reputation: 153

You can still use the REPL in SLIME when placed in the debugger, I routinely do this e.g. when errors occur. You just have to switch to the REPL buffer and type. It does not show a prompt initially, but it does once you give it an initial form.

Upvotes: 2

Related Questions