From: Helmut Eller <eller.helmut@gmail.com>
To: emacs-devel@gnu.org
Cc: Gemini Lasswell <gazally@runbox.com>
Subject: Re: backtrace-mode
Date: Wed, 20 Jun 2018 07:52:07 +0200 [thread overview]
Message-ID: <m2r2l2uhrs.fsf@gmail.com> (raw)
In-Reply-To: 871sd2mli3.fsf@runbox.com
On Tue, Jun 19 2018, Gemini Lasswell wrote:
> - Now that xref-find-definitions works in backtrace buffers, I think
> it would be better to stop making buttons for the functions in a
> backtrace, and to document M-. as the best way to jump to function
> definitions from backtraces. What do you think of this change to
> existing behavior, with or without a new customization variable to
> preserve the old behavior?
Apparently M-. in this backtrace-mode uses the elisp backend. While
that works, a backtrace-frame has potentially more context than just the
name of a global function. E.g. I have a custom "view source" command
that looks at the next frame and tries to find the function called
inside the function source. That works pretty well as long as there
aren't too many macros or lambdas involved. Also the compiler could
potentially emit debug information to map the frame's PC to the source
position; which would be very useful for lambdas. So I think there
should either be a proper "view source" command or xref backend for
backtraces.
Another issue: backtrace-get-frames seems to compute the entire
backtrace and all possibly relevant information in advance. Maybe that
should be done a bit more lazily, e.g. compute the next N frames only if
somebody needs them. For local variable also keep in mind that
backtrace--locals is implemented rather inefficiently. That would also
be less problematic if locals are only fetched when needed.
Helmut
next prev parent reply other threads:[~2018-06-20 5:52 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-06-19 22:58 backtrace-mode Gemini Lasswell
2018-06-20 5:52 ` Helmut Eller [this message]
2018-06-22 0:08 ` backtrace-mode Gemini Lasswell
2018-06-22 2:07 ` backtrace-mode Stefan Monnier
2018-06-22 5:41 ` backtrace-mode Gemini Lasswell
2018-06-20 12:32 ` backtrace-mode Stefan Monnier
2018-06-20 15:23 ` backtrace-mode Filipp Gunbin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=m2r2l2uhrs.fsf@gmail.com \
--to=eller.helmut@gmail.com \
--cc=emacs-devel@gnu.org \
--cc=gazally@runbox.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).