Hey Marc (and other Gambit folks, I realized this would be good for the gambit list too),
Your remote debugger is awesome. However, it travels further into the land of Gambit IO than I know. I'm having one problem with it (I got the latest version of it).
I found a rather concise example of the problem. It seems that when two errors happen close enough in time, one remote debugger pops open with the correct error, and another pops open with this error:
*** ERROR IN rdi-open-client, "Users/james/projects/scheme/gambit-iphone-example/lib/util/remote-debugger/rdi.scm"@108.5 -- Broken pipe (force-output '#<input-output-port #3 (tcp-client "localhost" 20000)>)
You can get it to do this by just doing this in the debugee:
(thread-start! (make-thread (lambda () (/ 1 0))))
(thread-start! (make-thread (lambda () (/ 1 0))))
Would you mind looking at it?
As a separate subject, as I was integrating the remote debugger with my iphone app, I realized I can not only have access to the debugger from the iphone, but I can also fire up a main REPL and interactively develop from my main computer on the iphone! That is very cool.
Now, I can't call (##repl-debug-main) in the primordial thread, as your proof of concept does, because the main thread is the program which needs to continue executing. So, my first attempt fired up the REPL from a child thread instead:
(thread-start! (make-thread (lambda () (##repl-debug-main))))
Do you see any problems with this? This seems to work fine (a real Gambit REPL pops open in an xterm when the app start in the iphone simulator). This got me thinking too: what is the relationship between stdin and stdout and the main REPL? It seems that standard output is somehow redirected to this REPL. Rather, if I call DISPLAY on any other thread it somehow appears in my above REPL. How is that so?
Thanks, James http://jlongster.com/