all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Nordlöw <per.nordlow@gmail.com>
To: help-gnu-emacs@gnu.org
Subject: Re: Feature Request: Auto-jumping to source file (.el) upon elisp  error
Date: Mon, 10 Dec 2007 02:40:44 -0800 (PST)	[thread overview]
Message-ID: <8042ecfb-c14b-4ed2-ae5e-a300c448e04d@b1g2000pra.googlegroups.com> (raw)
In-Reply-To: 85y7c2na3u.fsf@usenet.my.skamphausen.de

On Dec 10, 10:59 am, Stefan Kamphausen <ska...@gmx.net> wrote:
> Hi,
>
> "Nordlöw" <per.nord...@gmail.com> writes:
> > My highest priority Emacs feature request:
>
> > When I encounter an error in elisp code I always wonder: Is there a
> > way for Emacs to automatically split my elisp-error window in two and
> > replace one of the windows with the relating source file and jump to
> > position in that buffer where the error occurrred, like we are used to
> > with practically all other languages/IDEs?
>
> to me it seems that just the right thing happens.
>
> For example, when I start a un-customized emacs:
>
> shell> emacs -q
>
> put the following into my scratch buffer:
> ----------------------------------------------------------------------
> (defun produce-an-error ()
>   (interactive)
>   (goto-char))
>
> (setq debug-on-error t)
>
> (produce-an-error)
> ----------------------------------------------------------------------
>
> and do a M-x eval-current-buffer I get a second window showing a
> backtrace:
> ----------------------------------------------------------------------
> Debugger entered--Lisp error: (wrong-number-of-arguments goto-char 0)
>   (goto-char)
>   produce-an-error()
>   eval-current-buffer()
>   call-interactively(eval-current-buffer)
>   execute-extended-command(nil)
>   call-interactively(execute-extended-command)
> ----------------------------------------------------------------------
>
> The cute thing is that all known elisp functions (as opposed to
> C-builtins) will be clickable to jump to the function definition.
> Since I may be interested in various levels of the whole backtrace
> this is way better than having the program decide which one will be my
> point of interest.
>
> Just my 2ct.
>
> Regards,
> Stefan
> --
> Stefan Kamphausen ---http://www.skamphausen.de
> a blessed +42 regexp of confusion (weapon in hand)
> You hit. The format string crumbles and turns to dust.

But the top-most function, in your case produce-an-error(), is neither
clickable nor mentioned about its file/buffer-origin in the Debugger
output. This is sad because this is what the user/developer wants to
see first in order to most easily understand the top-most (call-stack)
context of the problem.

/Nordlöw

  reply	other threads:[~2007-12-10 10:40 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-12-10  8:54 Feature Request: Auto-jumping to source file (.el) upon elisp error Nordlöw
2007-12-10  9:59 ` Stefan Kamphausen
2007-12-10 10:40   ` Nordlöw [this message]
2007-12-10 12:14     ` Stefan Kamphausen
2007-12-10 14:27       ` Nordlöw
2007-12-10 18:47         ` Andreas Röhler
2007-12-10 19:11           ` Feature Request: Auto-jumping to source file (.el) upon elisperror Drew Adams
2007-12-11  7:05             ` Andreas Röhler
     [not found]         ` <mailman.4842.1197312462.18990.help-gnu-emacs@gnu.org>
2007-12-11  9:40           ` Feature Request: Auto-jumping to source file (.el) upon elisp error Nordlöw

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

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=8042ecfb-c14b-4ed2-ae5e-a300c448e04d@b1g2000pra.googlegroups.com \
    --to=per.nordlow@gmail.com \
    --cc=help-gnu-emacs@gnu.org \
    /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 external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.