Re: Lisp debugger problems.

2005-03-03 Thread Richard Stallman
What about advising the primitives that define functions to add debug-entry-code when a function is in debug-function-list? Would that work? Please do not think of making any part of Emacs advise primitives. That technique should never be used, because it causes confusion. All code i

Re: Lisp debugger problems.

2005-03-02 Thread Lute Kamstra
Richard Stallman <[EMAIL PROTECTED]> writes: > IIRC defadvice has some support for such things (e.g. you can > add an advice even before the function is defined). Maybe it'd > be a good idea to implement debug.el in terms of advice. > > Right now, the code to implement debug on entry

Re: Lisp debugger problems.

2005-03-02 Thread Richard Stallman
IIRC defadvice has some support for such things (e.g. you can add an advice even before the function is defined). Maybe it'd be a good idea to implement debug.el in terms of advice. Right now, the code to implement debug on entry is so simple that it would be a shame to use something

Re: Lisp debugger problems.

2005-03-01 Thread Lute Kamstra
Richard Stallman <[EMAIL PROTECTED]> writes: > What I don't understand in why debug-on-entry and > cancel-debug-on-entry call debugger-reenable as well (thus causing the > strange behavior in the example above). What am I missing? > > I am not certain. Perhaps the idea was in case yo

Re: Lisp debugger problems.

2005-02-28 Thread Stefan Monnier
>> Meanwhile, it would be nice and clean if redefining a function >> with defun, defmacro, defsubst or defalias were smart enough >> to turn debug-on-entry back on if it was on before. >> Want to do that? > Ok, I'll look into it. IIRC defadvice has some support for such things (e.g. you can add an

Re: Lisp debugger problems.

2005-02-28 Thread Lute Kamstra
Richard Stallman <[EMAIL PROTECTED]> writes: > What I don't understand in why debug-on-entry and > cancel-debug-on-entry call debugger-reenable as well (thus causing the > strange behavior in the example above). What am I missing? > > I am not certain. Perhaps the idea was in case yo

Re: Lisp debugger problems.

2005-02-28 Thread Richard Stallman
What I don't understand in why debug-on-entry and cancel-debug-on-entry call debugger-reenable as well (thus causing the strange behavior in the example above). What am I missing? I am not certain. Perhaps the idea was in case you do debugger-jump but you don't reenter the debugger.

Re: Lisp debugger problems.

2005-02-28 Thread Lute Kamstra
Lute Kamstra <[EMAIL PROTECTED]> writes: [...] > I investigated this problem a bit more. It seems that the bug only > happens when the body of a function contains just one sexp. For > example, when I do: > > (defun fun (a) "Docstring." (interactive) (1+ a)) > (debug-on-entry 'fun) > (fun

Re: Lisp debugger problems.

2005-02-27 Thread Lute Kamstra
Lute Kamstra <[EMAIL PROTECTED]> writes: [...] > A second problem I encountered is with debugger-jump. It is currently > not documented in the lisp manual so I'm trying to figure out what it > does. From what I understand, it is intended to work just like > debugger-continue with the difference

Lisp debugger problems.

2005-02-23 Thread Lute Kamstra
I'm checking the documentation of the lisp debugger (lispref/debugging.texi) and I ran into some problems. The first problem is with canceling the effect of debug-on-error by redefining a function. The lisp manual currently explains that I can use debug-on-entry to let a function enter the debugg