From: Andrew Psaltis <ampsaltis@gmail.com>
To: Andy Wingo <wingo@pobox.com>
Cc: 10581@debbugs.gnu.org
Subject: bug#10581: exit-hook is undocumented and is not called from a non-interactive environment
Date: Sun, 5 Feb 2012 14:20:13 -0500 [thread overview]
Message-ID: <CAM1tujLQCKmiJNE1EZ1_tmOd40h2PXb39jWe6bSyXMN-R2YDdQ@mail.gmail.com> (raw)
In-Reply-To: <87r4y9h52o.fsf@pobox.com>
On Sun, Feb 5, 2012 at 06:50, Andy Wingo <wingo@pobox.com> wrote:
> Hi Andrew,
>
> On Sun 22 Jan 2012 20:58, Andrew Psaltis <ampsaltis@gmail.com> writes:
>
>> After doing some web searches, I found an answer in "exit-hook",
>> except that it was not clear from the Guile reference manual that it
>> existed. It should probably be documented a little more clearly.
>
> It's not documented at all, actually. It was added in 1998 to
> boot-9.scm with the following comment:
>
> ;;; This hook is run at the very end of an interactive session.
> ;;;
> (define exit-hook (make-hook))
>
> It has not been changed since then.
>
Ah, yes.
>> When I write a scheme script that adds some function to exit-hook, it
>> is not invoked from a non-interactive call to guile.
>
> Indeed, as the comment notes.
>
> I think it's fair to say that this is a historical interface, and that
> it probably shouldn't be changed.
>
> Why not use atexit(), if you need to clean up the C library? Just
> wondering.
>
That would be because I forgot that it existed. I probably should
just use that instead.
Thanks.
~Andrew
next prev parent reply other threads:[~2012-02-05 19:20 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-01-22 19:58 bug#10581: exit-hook is undocumented and is not called from a non-interactive environment Andrew Psaltis
2012-01-23 2:08 ` Ian Price
2012-02-05 11:50 ` Andy Wingo
2012-02-05 19:20 ` Andrew Psaltis [this message]
2012-07-06 11:21 ` Andy Wingo
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=CAM1tujLQCKmiJNE1EZ1_tmOd40h2PXb39jWe6bSyXMN-R2YDdQ@mail.gmail.com \
--to=ampsaltis@gmail.com \
--cc=10581@debbugs.gnu.org \
--cc=wingo@pobox.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.
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).