From: Neil Jerram <neil@ossau.uklinux.net>
Cc: guile-user@gnu.org, spikegran@earthlink.net
Subject: Re: Guile top-level functions
Date: Wed, 19 Jan 2005 21:39:40 +0000 [thread overview]
Message-ID: <41EED39C.3080906@ossau.uklinux.net> (raw)
In-Reply-To: <87is5vfuvh.fsf@zip.com.au>
Kevin Ryde wrote:
>
> Actually I was thinking of something like
>
> (define callback noop)
> ...
> (set! callback (lambda () (display 'hello)))
> ...
> (callback)
>
> when the callback is made you'd like to know where that anonymous
> procedure came from.
Well:
guile> (source-properties (caddr (procedure-source callback)))
((breakpoint . #f) (line . 1) (column . 26) (filename . "standard input"))
But this assumes that the first form in the body is a pair (or more
generally, if tweaked, that the body contains _some_ pair), and I agree
that if would be nicer for the result of (procedure-source ...) to have
the source properties directly.
Neil
_______________________________________________
Guile-user mailing list
Guile-user@gnu.org
http://lists.gnu.org/mailman/listinfo/guile-user
next prev parent reply other threads:[~2005-01-19 21:39 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-01-16 19:54 Guile top-level functions Mike Gran
2005-01-17 0:05 ` Kevin Ryde
2005-01-17 8:38 ` Neil Jerram
2005-01-17 22:20 ` Kevin Ryde
2005-01-17 23:15 ` Neil Jerram
2005-01-18 0:23 ` Kevin Ryde
2005-01-19 21:39 ` Neil Jerram [this message]
2005-01-19 22:15 ` Kevin Ryde
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=41EED39C.3080906@ossau.uklinux.net \
--to=neil@ossau.uklinux.net \
--cc=guile-user@gnu.org \
--cc=spikegran@earthlink.net \
/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).