1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-04-30 03:40:34 +02:00

* continuations.c (scm_make_continuation): No longer a critical

section.
(scm_dynthrow):  Abort when scm_i_critical_section_level is
not zero.
This commit is contained in:
Marius Vollmer 2005-03-07 21:39:56 +00:00
parent 5e3545d00e
commit 8b7f0bb35b

View file

@ -21,7 +21,9 @@
#include "libguile/_scm.h"
#include <string.h>
#include <stdio.h>
#include "libguile/async.h"
#include "libguile/debug.h"
#include "libguile/root.h"
#include "libguile/stackchk.h"
@ -267,6 +269,12 @@ scm_dynthrow (SCM cont, SCM val)
SCM_STACKITEM *dst = thread->continuation_base;
SCM_STACKITEM stack_top_element;
if (scm_i_critical_section_level)
{
fprintf (stderr, "continuation invoked from within critical section.\n");
abort ();
}
#if SCM_STACK_GROWS_UP
if (dst + continuation->num_stack_items >= &stack_top_element)
grow_stack (cont, val);