Skip to content

Instantly share code, notes, and snippets.

@adh
Created February 12, 2012 12:51
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save adh/1808332 to your computer and use it in GitHub Desktop.
Save adh/1808332 to your computer and use it in GitHub Desktop.
$ ./dfsch-repl -r introspect
/\___/\ dfsch version 0.4.0-dev
( o o ) (rel-0.3.0-1310-g60bdd37) [Feb 12 2012 13:38:31]
== * == dfsch is free software, and you are welcome to redistribute it
) ( under certain conditions; see file COPYING for details.
]=> (define (foo x y) (let ((nx (1+ x)) (ny (1+ y))) (display "mnau") (newline) (+ nx ny)))
#<standard-function 0xa852d0 foo(x y)>
]=> (add-function-breakpoint! foo)
#<standard-function 0xa852d0 foo(x y)>
]=> (foo 3 4)
;; warning: leaving function with breakpoint on first form uncompiled
Program stopped on breakpoint:
(let ((nx (1+ x)) (ny (1+ y))) (display mnau) (newline) (+ nx ny))
Local variables:
y: 4
x: 3
... top level scope variables ommited
EOF to continue, ;disable to remove breakpoint, ;help for more commands
dbg1> ;step
Program stopped on breakpoint:
(#<form 0x7f90d8de2ca0 internal_let> ((nx (1+ x)) (ny (1+ y))) (display mnau) (newline) (+ nx ny))
Local variables:
y: 4
x: 3
... top level scope variables ommited
EOF to continue, ;disable to remove breakpoint, ;help for more commands
Program has trace trap, type ;continue to disable
dbg1> EOF
Program stopped on breakpoint:
(1+ x)
Local variables:
y: 4
x: 3
... top level scope variables ommited
EOF to continue, ;disable to remove breakpoint, ;help for more commands
Program has trace trap, type ;continue to disable
dbg1> EOF
Program stopped on breakpoint:
(1+ y)
Local variables:
y: 4
x: 3
... top level scope variables ommited
EOF to continue, ;disable to remove breakpoint, ;help for more commands
Program has trace trap, type ;continue to disable
dbg1> EOF
Program stopped on breakpoint:
(display mnau)
Local variables:
ny: 5
nx: 4
-- in next outer scope --
y: 4
x: 3
... top level scope variables ommited
EOF to continue, ;disable to remove breakpoint, ;help for more commands
Program has trace trap, type ;continue to disable
dbg1> EOF
mnauProgram stopped on breakpoint:
(newline)
Local variables:
ny: 5
nx: 4
-- in next outer scope --
y: 4
x: 3
... top level scope variables ommited
EOF to continue, ;disable to remove breakpoint, ;help for more commands
Program has trace trap, type ;continue to disable
dbg1> EOF
Program stopped on breakpoint:
(+ nx ny)
Local variables:
ny: 5
nx: 4
-- in next outer scope --
y: 4
x: 3
... top level scope variables ommited
EOF to continue, ;disable to remove breakpoint, ;help for more commands
Program has trace trap, type ;continue to disable
dbg1> EOF
9
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment