From: ludo@gnu.org (Ludovic Courtès)
To: guile-devel@gnu.org
Subject: Re: debug and backtrace
Date: Sun, 13 Sep 2009 16:30:38 +0200 [thread overview]
Message-ID: <87y6oilxwx.fsf@gnu.org> (raw)
In-Reply-To: 1252670144.24639.134.camel@localhost.localdomain
Hello!
Mike Gran <spk121@yahoo.com> writes:
> With the default behavior of 1.9.x, REPL debug and backtrace are broken.
Indeed, it looks like the VM frames are ignored.
Another example:
--8<---------------cut here---------------start------------->8---
scheme@(guile-user)> (letrec ((f (lambda (x) (g x))) (g (lambda (x) (x)))) (f (lambda () (make-stack #t))))
$1 = #<stack 6bebc0:ce3ce0>
scheme@(guile-user)> (display-backtrace $1 (current-output-port))
In unknown file:
?: 0* [#<vm 7002d0> #<program ce3da0 at <unknown port>:0:0 ()>]
?: 1* [make-stack #t #t]
scheme@(guile-user)> (stack-length $1)
$2 = 2
--8<---------------cut here---------------end--------------->8---
as opposed to:
--8<---------------cut here---------------start------------->8---
guile> (letrec ((f (lambda (x) (g x))) (g (lambda (x) (x)))) (f (lambda () (make-stack #t))))
$1 = #<stack 7f17ea928420:7f17ea8008a0>
guile> (display-backtrace $1 (current-output-port))
In unknown file:
?: 0* [primitive-eval (letrec ((f #) (g #)) (f (lambda () #)))]
1: 1* (letrec ((f (lambda # #)) (g (lambda # #))) (f (lambda () (make-stack #t))))
1: 2 [f #<procedure #f ()>]
...
1: 3 [gsubr-apply #<primitive-procedure make-stack> #t]
guile> (stack-length $1)
$2 = 4
--8<---------------cut here---------------end--------------->8---
I’ll try to investigate this.
Ludo’.
next prev parent reply other threads:[~2009-09-13 14:30 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-09-11 11:55 debug and backtrace Mike Gran
2009-09-13 14:30 ` Ludovic Courtès [this message]
2009-09-13 20:47 ` Neil Jerram
2009-09-16 19:31 ` Andy Wingo
2009-09-16 21:24 ` Neil Jerram
2009-09-17 12:24 ` Ludovic Courtès
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/guile/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87y6oilxwx.fsf@gnu.org \
--to=ludo@gnu.org \
--cc=guile-devel@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.
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).