scm_boot_guile_1() to ensure that stack base pointer is properly
initialized. There was no guarantee that variable i was the
highest/lowest variable on stack (i.e. the call frame of
scm_boot_guile was not completely protected from gc).
throw.c: Renamed last_debug_info_frame -> scm_last_debug_frame.
* throw.c: Renamed scm_catch --> scm_catch_apply and added more
arguments. The motivation is that code in root.c needs catch
functionality, and we want to avoid code duplication.
New functions: scm_catch, scm_lazy_catch. These are wrappers for
scm_catch_apply. scm_lazy_catch is intended to introduce catch
handlers that run without popping the stack into the dynwind
chain.
throw.c: Renamed last_debug_info_frame -> scm_last_debug_frame.
* root.c: Renamed `call-with-new-root' -->
`call-with-dynamic-root'.
(cwdr): Removed allocation of new root state. This should be done
separately by use of scm_make_root.
(scm_apply_with_dynamic_root): New function: Does what it
sounds like. Needed when spawning threads.
* throw.c: Renamed scm_catch --> scm_catch_apply and added more
arguments. The motivation is that code in root.c needs catch
functionality, and we want to avoid code duplication.
New functions: scm_catch, scm_lazy_catch. These are wrappers for
scm_catch_apply. scm_lazy_catch is intended to introduce catch
handlers that run without popping the stack into the dynwind
chain.
see if a given element of scm_dynwinds is a valid catch.
* throw.c (scm_ithrow): If scm_dynwinds has invalid list
structure, abort; don't just silently ignore the garbage.
numbers are), just call scm_small_istr2int to deal with it.
(scm_small_istr2int): New function, created by un-#ifdefing the
non-bignum version of scm_istr2int and renaming it.
* __scm.h: #undef SICP.
* pairs.h (SCM_EOL): Delete this definition, equating it with
SCM_BOOL_F.
* tags.h (SCM_EOL): Give it a new definition here; I think I found
the value it used to have. Doc fixes, too.
(scm_catch): Changed SCM_DEFER_INTS --> SCM_REDEFER_INTS and
SCM_ALLOW_INTS --> SCM_REALLOW_INTS. This is so that scm_catch
can be used in scm_call_with_new_root; Added reenabling of stack
checking when catching a throw.
(cwdr, scm_call_with_new_root, scm_dynamic_root, scm_app_wdr): New
functions: Implements dynamic roots mostly according to spec in
SCM manual. Main difference is that the second argument is a
throw handler rather than an error "thunk".
* root.h: Added declaration of scm_init_root.
SCM_THREAD_CRITICAL_SECTION_END. Moved marking of root data to
root.c:mark_root.
* * root.c, root.h: Added root smob.
(cwdr, scm_call_with_new_root, scm_dynamic_root, scm_app_wdr): New
functions: Implements dynamic roots mostly according to spec in
SCM manual. Main difference is that the second argument is a
throw handler rather than an error "thunk".
* root.c: Added #include "genio.h", #include "smob.h", #include
"pairs.h", #include "throw.h", #include "dynwind.h", #include
"eval.h"
(scm_init_root): Added #include "root.x".