From: Nick Dokos <nicholas.dokos@hp.com>
To: Eric Schulte <schulte.eric@gmail.com>
Cc: "Sébastien Vauban" <wxhgmqzgwmuf@spammotel.com>, emacs-orgmode@gnu.org
Subject: Re: Re: [babel] Executing sh-code
Date: Mon, 30 Nov 2009 11:02:09 -0500 [thread overview]
Message-ID: <8164.1259596929@alphaville.usa.hp.com> (raw)
In-Reply-To: Message from "Eric Schulte" <schulte.eric@gmail.com> of "Mon, 30 Nov 2009 08:44:55 MST." <yn4skbwyq2w.fsf@gmail.com>
Eric Schulte <schulte.eric@gmail.com> wrote:
> Hi S=C3=A9bastien,
>
> S=C3=A9bastien Vauban <wxhgmqzgwmuf@spammotel.com> writes:
>
> [...]
> >
> > Just for my information (maybe being able to be more accurate next time, =
> or
> > even finding a solution myself), how do you debug such a problem?
> >
> > With which debugger, with tracing/stepping? With stack trace?
> >
>
> I'm almost embarrassed to admit that I do most of my elisp debugging
> with the `message' function. I embed `message' debug statements to
> print the values of key variables at key points, and I run through
> problems looking at the output.
>
> I'd be interested to hear if anyone can recommend a better elisp
> debugging solution.
>
There are two methods that I use that I think are much more effective
than sprinkling message calls all over the place:
o edebug-defun: (in emacs-lisp mode, C-u C-M-x) will mark the
function so that when it is called, the interpreter stops and you can then
single-step through it with <SPACE>. At each point, you can
press "e" and evaluate variables (actually arbitrary expressions).
o Insert a strategically placed (debug) call and then call the function.
If/when the debug call is executed, you are dropped into the debugger
and you can then evaluate arbitrary expressions.
HTH,
Nick
next prev parent reply other threads:[~2009-11-30 16:03 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-11-25 14:22 [babel] Executing sh-code Sébastien Vauban
2009-11-27 9:15 ` Sébastien Vauban
2009-11-27 10:46 ` Eric S Fraga
2009-11-27 10:00 ` Torsten Wagner
2009-11-27 10:43 ` Sébastien Vauban
2009-11-27 19:32 ` Eric Schulte
2009-11-27 19:46 ` Dan Davison
2009-11-29 21:03 ` Sébastien Vauban
2009-11-30 15:44 ` Eric Schulte
2009-11-30 16:02 ` Nick Dokos [this message]
2009-11-30 16:16 ` Eric Schulte
2009-12-01 8:37 ` Sébastien Vauban
2009-12-01 10:01 ` Sébastien Vauban
2009-12-02 19:09 ` Eric Schulte
2009-12-04 13:25 ` Sébastien Vauban
2009-12-04 14:09 ` Sébastien Vauban
2009-12-04 17:04 ` Eric Schulte
2009-12-07 1:10 ` Torsten Wagner
2009-12-07 9:59 ` Sébastien Vauban
2009-12-04 17:03 ` Eric Schulte
2009-12-02 14:55 ` Sébastien Vauban
2009-12-02 20:16 ` Eric Schulte
2009-12-03 9:27 ` Sébastien Vauban
2009-12-03 16:06 ` Eric Schulte
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.orgmode.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=8164.1259596929@alphaville.usa.hp.com \
--to=nicholas.dokos@hp.com \
--cc=emacs-orgmode@gnu.org \
--cc=schulte.eric@gmail.com \
--cc=wxhgmqzgwmuf@spammotel.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/org-mode.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).