[gambit-list] Debugging Scheme in Eclipse

William Cook wcook at cs.utexas.edu
Sun Jun 1 18:50:59 EDT 2008

I'm doing some serious development in Scheme, and want a
good visual debugger. Since none of the scheme developers
I've talked to seem to be interested in the problem (except JazzScheme, 
and they are not close to ready), I've
started building one myself, as an Eclipse plugin.
I am modifying the sample to be a general-purpose debugging
interface for any dynamic language:
It's going pretty well. Combined with SchemeWay, we might have
a great IDE for Scheme without much effort.

My goal is to support:
* visual stack frame inspection
* incremental inspection of other objects, including closures
* UI for stepping into, over, and out of procedures
* ability to continue with an expression result
* line-based breakpoints
* possibly some extensions for tracing

My sense is that I can get much of this without any changes
to the gambit runtime. Line-based breakpoints are one thing that
may not be possible without runtime support.

I have a prototype working now, which gives me confidence
that its possible. I still have a few problems:

* I need to be able to gain control each time the REPL stops.
I know how to do this for exceptions (current-exception-hander),
but i'm not sure how to
do it for stepping, without copying ##repl-within, which i
would prefer not to do.

* Specifically, is there any way to hack into define-prim

* As mentioned above, line-based breakpoints are a problem.

* The way that variables are changed to %%n23 is annoying.
I will strip that off, but it's ambiguous what to do with
the transformed form of variables ending in digits, like x1.

* There are probably more issues I haven't run into yet.

If anybody has any advice, or wants to help out, let me know.

William Cook
Assistant Professor
UT Austin Computer Sciences

PS: The fact that this is going to be a general purpose
debugging interface is interesting. It could easily work for
Ruby, Python, Perl, in addition to other versions of Scheme.

More information about the Gambit-list mailing list