GNU bug report logs - #6991
Please keep bytecode out of *Backtrace* buffers

Previous Next

Package: emacs;

Reported by: jidanni <at> jidanni.org

Date: Tue, 7 Sep 2010 01:34:01 UTC

Severity: wishlist

Tags: fixed, notabug

Merged with 15789

Found in version 24.3.50

Fixed in version 26.1

Done: npostavs <at> users.sourceforge.net

Bug is archived. No further changes may be made.

Full log


Message #201 received at 6991 <at> debbugs.gnu.org (full text, mbox):

From: Stefan Monnier <monnier <at> IRO.UMontreal.CA>
To: npostavs <at> users.sourceforge.net
Cc: lekktu <at> gmail.com, johnw <at> gnu.org, 6991 <at> debbugs.gnu.org,
 Eli Zaretskii <eliz <at> gnu.org>, larsi <at> gnus.org, drew.adams <at> oracle.com
Subject: Re: bug#6991: Please keep bytecode out of *Backtrace* buffers
Date: Mon, 26 Jun 2017 10:54:06 -0400
> Ah, sorry, my memory of the old code got a little fuzzy, it doesn't
> correspond to backtrace--print-frame (that function only contains the
> code which reads the :debug-on-exit flag).  It's actually replacing the
> code removed in this hunk:

> @@ -301,10 +319,7 @@ (defun debugger-setup-buffer (args)
>         (setq pos (point))
>         (setq debugger-value (nth 1 args))
>         (prin1 debugger-value (current-buffer))
> -       (insert ?\n)
> -       (delete-char 1)
> -       (insert ? )
> -       (beginning-of-line))
> +       (insert ?\n))
>        ;; Watchpoint triggered.
>        ((and `watchpoint (let `(,symbol ,newval . ,details) (cdr args)))
>         (insert

> So it's another instance of operating on the backtrace frame object
> directly, instead of manipulating the text after printing (i.e.,
> unsetting the :debug-on-exit flag instead of erasing its representation
> "*" in the buffer).

Ah, yes, I see it now, thanks.  It's a good change, then: the new code
is more clear.  I wonder why we do that, tho:
the previous code didn't have a comment, so I'm left guessing that maybe
it's that we don't want to advertise as "will stop when exiting foo"
a function which we're exiting?

> Also, as I'm looking at this, I wonder if I should replace the (prin1
> debugger-value ...) calls with (funcall debugger-print-function ...)

Sounds right.

> too.  Hmm, and I probably shouldn't have moved those print-*
> let-bindings at all because they could be relevant to the code printing
> "frame 0".

Good point.


        Stefan




This bug report was last modified 7 years and 254 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.