summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--libguile/async.c8
-rw-r--r--libguile/dynwind.c20
-rw-r--r--libguile/dynwind.h18
-rw-r--r--libguile/fluids.c12
-rw-r--r--libguile/ports.c6
5 files changed, 34 insertions, 30 deletions
diff --git a/libguile/async.c b/libguile/async.c
index b4b8eb4e6..34165fe11 100644
--- a/libguile/async.c
+++ b/libguile/async.c
@@ -367,8 +367,8 @@ scm_c_call_with_unblocked_asyncs (void *(*proc) (void *data), void *data)
void
scm_frame_block_asyncs ()
{
- scm_frame_rewind (increase_block, NULL, SCM_F_WIND_EXPLICITLY);
- scm_frame_unwind (decrease_block, NULL, SCM_F_WIND_EXPLICITLY);
+ scm_frame_rewind_handler (increase_block, NULL, SCM_F_WIND_EXPLICITLY);
+ scm_frame_unwind_handler (decrease_block, NULL, SCM_F_WIND_EXPLICITLY);
}
void
@@ -377,8 +377,8 @@ scm_frame_unblock_asyncs ()
if (scm_root->block_asyncs == 0)
scm_misc_error ("scm_with_unblocked_asyncs",
"asyncs already unblocked", SCM_EOL);
- scm_frame_rewind (decrease_block, NULL, SCM_F_WIND_EXPLICITLY);
- scm_frame_unwind (increase_block, NULL, SCM_F_WIND_EXPLICITLY);
+ scm_frame_rewind_handler (decrease_block, NULL, SCM_F_WIND_EXPLICITLY);
+ scm_frame_unwind_handler (increase_block, NULL, SCM_F_WIND_EXPLICITLY);
}
diff --git a/libguile/dynwind.c b/libguile/dynwind.c
index ca2fb704d..28dbb0d45 100644
--- a/libguile/dynwind.c
+++ b/libguile/dynwind.c
@@ -120,8 +120,8 @@ scm_internal_dynamic_wind (scm_t_guard before,
SCM ans;
scm_frame_begin (SCM_F_FRAME_REWINDABLE);
- scm_frame_rewind (before, guard_data, SCM_F_WIND_EXPLICITLY);
- scm_frame_unwind (after, guard_data, SCM_F_WIND_EXPLICITLY);
+ scm_frame_rewind_handler (before, guard_data, SCM_F_WIND_EXPLICITLY);
+ scm_frame_unwind_handler (after, guard_data, SCM_F_WIND_EXPLICITLY);
ans = inner (inner_data);
scm_frame_end ();
return ans;
@@ -188,8 +188,8 @@ winder_mark (SCM w)
}
void
-scm_frame_unwind (void (*proc) (void *), void *data,
- scm_t_wind_flags flags)
+scm_frame_unwind_handler (void (*proc) (void *), void *data,
+ scm_t_wind_flags flags)
{
SCM w;
scm_t_bits fl = ((flags&SCM_F_WIND_EXPLICITLY)? WINDER_F_EXPLICIT : 0);
@@ -199,8 +199,8 @@ scm_frame_unwind (void (*proc) (void *), void *data,
}
void
-scm_frame_rewind (void (*proc) (void *), void *data,
- scm_t_wind_flags flags)
+scm_frame_rewind_handler (void (*proc) (void *), void *data,
+ scm_t_wind_flags flags)
{
SCM w;
SCM_NEWSMOB2 (w, tc16_winder | WINDER_F_REWIND,
@@ -211,8 +211,8 @@ scm_frame_rewind (void (*proc) (void *), void *data,
}
void
-scm_frame_unwind_with_scm (void (*proc) (SCM), SCM data,
- scm_t_wind_flags flags)
+scm_frame_unwind_handler_with_scm (void (*proc) (SCM), SCM data,
+ scm_t_wind_flags flags)
{
SCM w;
scm_t_bits fl = ((flags&SCM_F_WIND_EXPLICITLY)? WINDER_F_EXPLICIT : 0);
@@ -222,8 +222,8 @@ scm_frame_unwind_with_scm (void (*proc) (SCM), SCM data,
}
void
-scm_frame_rewind_with_scm (void (*proc) (SCM), SCM data,
- scm_t_wind_flags flags)
+scm_frame_rewind_handler_with_scm (void (*proc) (SCM), SCM data,
+ scm_t_wind_flags flags)
{
SCM w;
SCM_NEWSMOB2 (w, tc16_winder | WINDER_F_REWIND | WINDER_F_MARK,
diff --git a/libguile/dynwind.h b/libguile/dynwind.h
index f619b46b5..ce68bcd64 100644
--- a/libguile/dynwind.h
+++ b/libguile/dynwind.h
@@ -53,15 +53,15 @@ typedef enum {
SCM_API void scm_frame_begin (scm_t_frame_flags);
SCM_API void scm_frame_end (void);
-SCM_API void scm_frame_unwind (void (*func) (void *), void *data,
- scm_t_wind_flags);
-SCM_API void scm_frame_rewind (void (*func) (void *), void *data,
- scm_t_wind_flags);
-
-SCM_API void scm_frame_unwind_with_scm (void (*func) (SCM), SCM data,
- scm_t_wind_flags);
-SCM_API void scm_frame_rewind_with_scm (void (*func) (SCM), SCM data,
- scm_t_wind_flags);
+SCM_API void scm_frame_unwind_handler (void (*func) (void *), void *data,
+ scm_t_wind_flags);
+SCM_API void scm_frame_rewind_handler (void (*func) (void *), void *data,
+ scm_t_wind_flags);
+
+SCM_API void scm_frame_unwind_handler_with_scm (void (*func) (SCM), SCM data,
+ scm_t_wind_flags);
+SCM_API void scm_frame_rewind_handler_with_scm (void (*func) (SCM), SCM data,
+ scm_t_wind_flags);
#ifdef GUILE_DEBUG
SCM_API SCM scm_wind_chain (void);
diff --git a/libguile/fluids.c b/libguile/fluids.c
index 3f5591759..6cae477cc 100644
--- a/libguile/fluids.c
+++ b/libguile/fluids.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1996,1997,2000,2001 Free Software Foundation, Inc.
+/* Copyright (C) 1996,1997,2000,2001, 2004 Free Software Foundation, Inc.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
@@ -229,8 +229,10 @@ scm_c_with_fluids (SCM fluids, SCM values, SCM (*cproc) (), void *cdata)
data = scm_cons (fluids, values);
scm_frame_begin (SCM_F_FRAME_REWINDABLE);
- scm_frame_rewind_with_scm (swap_fluids, data, SCM_F_WIND_EXPLICITLY);
- scm_frame_unwind_with_scm (swap_fluids_reverse, data, SCM_F_WIND_EXPLICITLY);
+ scm_frame_rewind_handler_with_scm (swap_fluids, data,
+ SCM_F_WIND_EXPLICITLY);
+ scm_frame_unwind_handler_with_scm (swap_fluids_reverse, data,
+ SCM_F_WIND_EXPLICITLY);
ans = cproc (cdata);
scm_frame_end ();
return ans;
@@ -275,8 +277,8 @@ void
scm_frame_fluid (SCM fluid, SCM value)
{
SCM data = scm_cons (fluid, value);
- scm_frame_rewind_with_scm (swap_fluid, data, SCM_F_WIND_EXPLICITLY);
- scm_frame_unwind_with_scm (swap_fluid, data, SCM_F_WIND_EXPLICITLY);
+ scm_frame_rewind_handler_with_scm (swap_fluid, data, SCM_F_WIND_EXPLICITLY);
+ scm_frame_unwind_handler_with_scm (swap_fluid, data, SCM_F_WIND_EXPLICITLY);
}
void
diff --git a/libguile/ports.c b/libguile/ports.c
index 45085e887..6e1446610 100644
--- a/libguile/ports.c
+++ b/libguile/ports.c
@@ -453,8 +453,10 @@ scm_frame_current_foo_port (SCM port,
data->getter = getter;
data->setter = setter;
- scm_frame_rewind_with_scm (swap_port, scm_data, SCM_F_WIND_EXPLICITLY);
- scm_frame_unwind_with_scm (swap_port, scm_data, SCM_F_WIND_EXPLICITLY);
+ scm_frame_rewind_handler_with_scm (swap_port, scm_data,
+ SCM_F_WIND_EXPLICITLY);
+ scm_frame_unwind_handler_with_scm (swap_port, scm_data,
+ SCM_F_WIND_EXPLICITLY);
}
void