From: Kevin Ryde <user42@zip.com.au>
Subject: SCM_DEFER_INTS versus error
Date: Tue, 05 Aug 2003 11:37:17 +1000 [thread overview]
Message-ID: <87el0028c2.fsf@zip.com.au> (raw)
I noticed in the little program below, the thread seems to get hung
after an error in the mainline has done an SCM_DEFER_INTS in strptime
then escaped with an error, apparently not doing an SCM_ALLOW_INTS.
Is there a theory on what should happen with this? Is an error meant
to re-allow ints or should code be careful to do an ALLOW after any
DEFER? The latter no doubt makes sense irrespective of what an error
throw does.
Incidentally, I don't think I understand why current-time has a
SCM_DEFER_INTS. A simple call to time() ought to be safe shouldn't
it?
(use-modules (ice-9 threads))
(begin-thread
(display "thread started\n")
(sleep 2)
(display "thread awake again\n")
(display "thread trying current-time\n")
(current-time)
(display "thread done\n"))
(sleep 1)
(catch #t
(lambda () (strptime "xxx" "%Y"))
(lambda args
(display "main caught strptime error\n")))
(sleep 10)
(display "main exiting\n")
_______________________________________________
Guile-devel mailing list
Guile-devel@gnu.org
http://mail.gnu.org/mailman/listinfo/guile-devel
next reply other threads:[~2003-08-05 1:37 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-08-05 1:37 Kevin Ryde [this message]
2003-09-17 22:58 ` SCM_DEFER_INTS versus error Marius Vollmer
2003-09-19 20:34 ` Tom Lord
2003-09-22 18:01 ` Marius Vollmer
2003-09-20 23:44 ` Kevin Ryde
2003-09-22 18:10 ` Marius Vollmer
2003-09-23 1:01 ` Mikael Djurfeldt
2003-10-07 17:54 ` Marius Vollmer
2003-12-06 21: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=87el0028c2.fsf@zip.com.au \
--to=user42@zip.com.au \
/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).