summaryrefslogtreecommitdiff
path: root/libguile/continuations.h
diff options
context:
space:
mode:
authorAndy Wingo <wingo@pobox.com>2010-02-07 14:50:51 +0100
committerAndy Wingo <wingo@pobox.com>2010-02-08 13:35:42 +0100
commit269479e31f70d40a82b75be87c1b2a7363c85696 (patch)
tree8b8f8603e0a5610de57c1258dae7b8e89aa7139b /libguile/continuations.h
parent997659f898d94abccdcba3c444b84e3c6f6e963e (diff)
downloadguile-269479e31f70d40a82b75be87c1b2a7363c85696.tar.gz
scm_i_make_continuation takes vm and vm_cont args explicitly
* libguile/continuations.h: * libguile/continuations.c (scm_i_make_continuation): Take VM and VM continuation arguments as well; I'm not convinced that saving all VM continuations was the right thing, and in any case we only ever saved the latest. Running a new VM should create a continuation barrier. * libguile/stacks.c (scm_make_stack): * libguile/vm-i-system.c (call/cc, tail-call/cc): Adapt callers. * libguile/vm.h (scm_i_vm_capture_continuation) (scm_i_vm_reinstate_continuation): Change to be internal, and to only capture and reinstate continuations for a particular VM.
Diffstat (limited to 'libguile/continuations.h')
-rw-r--r--libguile/continuations.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/libguile/continuations.h b/libguile/continuations.h
index 93b8dc750..a9d2feee0 100644
--- a/libguile/continuations.h
+++ b/libguile/continuations.h
@@ -53,7 +53,8 @@ typedef struct
#endif /* __ia64__ */
size_t num_stack_items; /* size of the saved stack. */
SCM root; /* continuation root identifier. */
- SCM vm_conts; /* vm continuations (they use separate stacks) */
+ SCM vm; /* vm */
+ SCM vm_cont; /* vm's stack and regs */
/* The offset from the live stack location to this copy. This is
used to adjust pointers from within the copied stack to the stack
@@ -71,7 +72,7 @@ typedef struct
-SCM_INTERNAL SCM scm_i_make_continuation (int *first);
+SCM_INTERNAL SCM scm_i_make_continuation (int *first, SCM vm, SCM vm_cont);
SCM_INTERNAL SCM scm_i_call_with_current_continuation (SCM proc);
SCM_INTERNAL SCM scm_i_continuation_to_frame (SCM cont);
SCM_INTERNAL void scm_i_continuation_call (SCM cont, size_t n, SCM *argv);