(defun foo (x y) (declare (optimize (debug 0))) (+ x y))
In READ-ARGLIST DI::DEBUG-FUNCTION-LAMBDA-LIST signals LAMBDA-LIST-UNAVAILABLE. Naive fix below.
Cheers, Gabor Melis
Index: swank-cmucl.lisp =================================================================== RCS file: /project/slime/cvsroot/slime/swank-cmucl.lisp,v retrieving revision 1.97 diff -u -r1.97 swank-cmucl.lisp --- swank-cmucl.lisp 21 Apr 2004 19:46:40 -0000 1.97 +++ swank-cmucl.lisp 23 Apr 2004 21:40:01 -0000 @@ -986,10 +986,13 @@ ;; this should work both for ;; compiled-debug-function and for ;; interpreted-debug-function - (t (let ((df (di::function-debug-function fun))) - (if df - (debug-function-arglist df) - "(<arglist-unavailable>)")))))) + (t (let ((df (di::function-debug-function fun)) + (unavailable "(<arglist-unavailable>)")) + (if df + (handler-case (debug-function-arglist df) + (di::lambda-list-unavailable () + unavailable)) + unavailable)))))) (check-type arglist (or list string)) arglist))
Gabor Melis mega@hotpop.com writes:
In READ-ARGLIST DI::DEBUG-FUNCTION-LAMBDA-LIST signals LAMBDA-LIST-UNAVAILABLE.
Is that a problem? The docstring for swank:arglist says: "An error should be signaled if the lambda-list cannot be found".
I think all calls to arglist are protected with an ignore-errors form. Do you use it for something else? Perhaps we should return a special marker like :dont-know if the lambda-list is not available.
Helmut.
On Saturday 24 April 2004 00:21, Helmut Eller wrote:
Gabor Melis mega@hotpop.com writes:
In READ-ARGLIST DI::DEBUG-FUNCTION-LAMBDA-LIST signals LAMBDA-LIST-UNAVAILABLE.
Is that a problem? The docstring for swank:arglist says: "An error should be signaled if the lambda-list cannot be found".
Yes. Typing an invocation of foo puts me into the debugger after every each space pressed which is highy annoying. Surely, its isn't the intended behavour, is it?
I think all calls to arglist are protected with an ignore-errors form. Do you use it for something else? Perhaps we should return a special marker like :dont-know if the lambda-list is not available.
Helmut.
Gabor Melis mega@hotpop.com writes:
Yes. Typing an invocation of foo puts me into the debugger after every each space pressed which is highy annoying. Surely, its isn't the intended behavour, is it?
Of course that's annoying, but I didn't see it with in your example. I changed the arglist code anyway, so that these conditions are trapped.
Helmut.
On Sunday 25 April 2004 08:56, Helmut Eller wrote:
Gabor Melis mega@hotpop.com writes:
Yes. Typing an invocation of foo puts me into the debugger after every each space pressed which is highy annoying. Surely, its isn't the intended behavour, is it?
Of course that's annoying, but I didn't see it with in your example.
I was a bit too concise :-).
I changed the arglist code anyway, so that these conditions are trapped.
Thanks, it works.
Helmut.
Gabor