1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-05-01 20:30:28 +02:00
Commit graph

5235 commits

Author SHA1 Message Date
Neil Jerram
05b454920e (scm_uniform_vector_read_x): Declare base as char*
rather than void*, so we can do pointer arithmetic on it.
(Reported by Mike Gran.)
(s_scm_uniform_vector_write): Ditto.
2006-03-11 12:32:25 +00:00
Neil Jerram
41352a0ab0 (scm_make_shared_array): Don't use SCM_I_ARRAY_BASE when
oldra is not an array.  (Reported by Steve Juranich.)
2006-03-10 23:59:33 +00:00
Neil Jerram
b82115b8ba (do_unlock): Renamed from "unlock", which is defined
in unistd.h on QNX.  (Reported by Matt Kraai.)
2006-03-10 23:04:46 +00:00
Kevin Ryde
e1110dcbdf *** empty log message *** 2006-03-03 23:58:32 +00:00
Kevin Ryde
f367635227 Copyright year 2006-03-03 23:57:27 +00:00
Kevin Ryde
b89dc7ae57 Change comments from C++ to C style. Reported by Mike Gran. 2006-03-03 23:56:51 +00:00
Kevin Ryde
1b52ef74b7 *** empty log message *** 2006-03-03 23:36:58 +00:00
Kevin Ryde
51d123b40c (scm_i_defer_ints_etc): Show SCM_DEFER_INTS in message,
not SCM_CRITICAL_SECTION_START.
2006-03-03 23:35:57 +00:00
Kevin Ryde
6c4015417a *** empty log message *** 2006-02-27 16:37:34 +00:00
Kevin Ryde
b0ef6db3d0 (bitvector_set): Use h->writable_elements not h->elements. 2006-02-27 16:34:12 +00:00
Kevin Ryde
dbc82ba387 *** empty log message *** 2006-02-25 21:23:33 +00:00
Kevin Ryde
d34a52e744 (scm_readdir): Use fpathconf for the dirent size when
NAME_MAX is not available, which is so on Solaris 10.  Report and help
by Bill Schottstaedt.
2006-02-25 21:22:30 +00:00
Kevin Ryde
b39546b95f *** empty log message *** 2006-02-25 20:51:32 +00:00
Kevin Ryde
c39ca281a3 (MY_VALIDATE_SUBSTRING_SPEC_UCOPY): New macro.
(scm_string_compare, scm_string_compare_ci, scm_string_lt,
scm_string_gt, scm_string_le, scm_string_ge, scm_string_ci_lt,
scm_string_ci_gt, scm_string_ci_le, scm_string_ci_ge): In comparisons
use "unsigned char", not signed char.  This ensures comparisons are
the same as `char<?' etc, and is also the same as guile 1.6 did.
Reported by Sven Hartrumpf.
2006-02-25 20:50:02 +00:00
Marius Vollmer
cbd17f3783 *** empty log message *** 2006-02-20 21:17:59 +00:00
Marius Vollmer
5f25a9a1a7 Test for SCM_HAVE_T_UINT64 instead of
SCM_HAVE_T_INT64.
(scm_i_uniform32, scm_i_uniform32, scm_i_init_rstate): Use
scm_t_uint64 and scm_t_uint32 instead of scm_t_int64 and
scm_t_int32.
2006-02-20 21:17:37 +00:00
Kevin Ryde
908c45434e *** empty log message *** 2006-02-15 00:40:13 +00:00
Kevin Ryde
0e84f2fea2 2006-02-14 Ludovic Courtès <ludovic.courtes@laas.fr>
* gc-malloc.c (decrease_mtrigger): Make sure SIZE is lower than or
	equal to SCM_MALLOCATED.
2006-02-15 00:38:44 +00:00
Kevin Ryde
a0e39346e2 2006-02-14 Ludovic Courtès <ludovic.courtes@laas.fr>
* strings.c (scm_i_take_stringbufn): Register LEN+1 bytes instead of
	LEN.  Without this, too much collectable memory gets unregistered,
	which results in an underflow of SCM_MALLOCATED in
	`decrease_mtrigger()'.
2006-02-15 00:36:58 +00:00
Marius Vollmer
677ad9d214 (scm_eval_body): Use scm_i_dynwind_pthread_mutex_lock
oinstead of scm_dynwind_pthread_mutex_lock so that it works when
configured --without-threads.
(SCM_APPLY, CEVAL): Likewise.  Thanks to Han-Wen Nienhuys!
2006-02-12 22:54:29 +00:00
Marius Vollmer
0ab652a386 Added 2006 to copyright years in every file, as per the new rules. 2006-02-12 13:42:52 +00:00
Marius Vollmer
c3eed9ee87 Fixed typo. 2006-02-12 12:40:58 +00:00
Marius Vollmer
bbcade428b * deprecated.scm (make-uniform-array): Don't pass the prototype as
the fill value, dimensions->uniform-array will do the right thing
now.  See scm_dimensions_to_uniform_array why we need to be tricky
about the fill value.

* unif.c (scm_dimensions_to_uniform_array): Use the prototype for
filling when the fill paramater is omitted, as documented, but
turn #\nul into 0 since s8 arrays (signified by a #\nul prototype)
can not store characters.
2006-02-12 00:57:14 +00:00
Neil Jerram
58b1ceaf5c (scm_c_make_socket_address): Pass address_size pointer
on to scm_fill_sockaddr call.
2006-02-09 14:08:12 +00:00
Kevin Ryde
689596d425 *** empty log message *** 2006-02-06 20:43:27 +00:00
Neil Jerram
43e01b1ee3 * throw.h (scm_c_catch, scm_c_with_throw_handler,
scm_catch_with_pre_unwind_handler, scm_with_throw_handler): New.

* throw.c (SCM_JBPREUNWIND, SCM_SETJBPREUNWIND): New.
(struct pre_unwind_data): New, replaces struct lazy_catch.
(scm_c_catch): New, replaces scm_internal_catch as the primary
catch API for C code; adds pre-unwind handler support.
(scm_internal_catch): Now just a wrapper for scm_c_catch, for back
compatibility.
(tc16_pre_unwind_data, pre_unwind_data_print,
make_pre_unwind_data, SCM_PRE_UNWIND_DATA_P): Renamed from
"lazy_catch" equivalents.
(scm_c_with_throw_handler): New, replaces scm_internal_lazy_catch
as the primary C API for a "lazy" catch.
(scm_internal_lazy_catch): Now just a wrapper for
scm_c_with_throw_handler, for back compatibility.
(scm_catch_with_pre_unwind_handler): Renamed from scm_catch; adds
pre-unwind handler support.
(scm_catch): Now just a wrapper for
scm_catch_with_pre_unwind_handler, for back compatibility.
(scm_with_throw_handler): New.
(scm_lazy_catch): Update comment to say that the handler can
return, and what happens if it does.
(toggle_pre_unwind_running): New.
(scm_ithrow): When identifying the throw target, take running
flags into account.  In general, change naming of things from
"lazy_catch" to "pre_unwind".  When throwing to a throw handler,
don't unwind the dynamic context first.  Add dynwind framing to
manage the running flag of a throw handler.  If a lazy catch or
throw handler returns, rethrow the same exception again.  Add
pre-unwind support to the normal catch case (SCM_JMPBUFP).

* root.c (scm_internal_cwdr): Add NULL args to
scm_i_with_continuation_barrier call.

* dynwind.c: Change comment mentioning lazy-catch to mention
pre-unwind data and throw handler also.

* continuations.h (scm_i_with_continuation_barrier): Add
pre-unwind handler args.

* continuations.c (scm_i_with_continuation_barrier): Add
pre-unwind handler args, and pass on to scm_c_catch (changed from
scm_internal_catch).
(c_handler): Remove scm_handle_by_message_noexit call.
(scm_c_with_continuation_barrier): Call
scm_i_with_continuation_barrier with scm_handle_by_message_noexit
as the pre-unwind handler.
(scm_handler): Remove scm_handle_by_message_noexit call.
(s_scm_with_continuation_barrier): Call
scm_i_with_continuation_barrier with scm_handle_by_message_noexit
as the pre-unwind handler.
2006-02-04 14:36:24 +00:00
Kevin Ryde
71c7cfa502 (scm_mark_all): Fix c99-isms "loops" and "again" variables. 2006-02-03 23:49:37 +00:00
Kevin Ryde
e46e8468a5 add a copyright year for 2005 changes 2006-02-02 21:27:44 +00:00
Kevin Ryde
7209892804 *** empty log message *** 2006-02-02 21:20:46 +00:00
Kevin Ryde
303bddc879 (scm_list): Restore this function for use from C.
It's a complete no-op but in theory might used by someone.
2006-02-02 21:15:48 +00:00
Marius Vollmer
aa092c5d7f *** empty log message *** 2006-01-29 23:13:11 +00:00
Marius Vollmer
cce0e9c875 (scm_eval_body): Lock source_mutex with a dynwind context
so that it gets unlocked in all cases.
(SCM_APPLY, CEVAL): Likewise.
2006-01-29 23:12:01 +00:00
Marius Vollmer
ee51ba3115 *** empty log message *** 2006-01-29 20:00:14 +00:00
Marius Vollmer
718866aa75 (scm_array_map_x): Don't use scm_array_p, use scm_is_typed_array
instead.
2006-01-29 19:59:51 +00:00
Marius Vollmer
99e370f645 *** empty log message *** 2006-01-29 19:38:29 +00:00
Marius Vollmer
2f263a6a0b * futures.h, futures.c: Wrap whole contents in "#if 0"/"#endif".
* eval.c, init.c: Comment out all 'future' related things.
2006-01-29 19:09:52 +00:00
Marius Vollmer
661ae7ab6b Renamed the "frames" that are related to dynamic-wind to "dynamic
contexts.  Renamed all functions from scm_frame_ to scm_dynwind_.
Updated documentation.
2006-01-29 00:23:28 +00:00
Marius Vollmer
15ccf10bf2 *** empty log message *** 2006-01-28 22:01:58 +00:00
Marius Vollmer
d5ad4aa6fa * inline.h, pairs.c (scm_is_pair): Moved scm_is_pair from pairs.c
to inline.h to make it inline.
2006-01-28 22:01:35 +00:00
Han-Wen Nienhuys
fd0a5bbcb7 patches by Ludovic Courtès for symbol generation. 2006-01-24 20:30:09 +00:00
Han-Wen Nienhuys
2ca2ffe6b2 ("sweep_card"): don't count scm_tc_free_cell for
free_count.
2006-01-18 10:17:30 +00:00
Han-Wen Nienhuys
c255614e26 *** empty log message *** 2006-01-01 19:46:24 +00:00
Neil Jerram
29295b0c90 (next_fluid_num): [From Ludovic Courtès:] Don't trigger
the GC when allocated_fluids_len is zero.
2005-12-29 10:26:39 +00:00
Neil Jerram
ec3a8ace63 * api-evaluation.texi (Loading): Document custom reader.
* boot-9.scm (load-module): Support an optional custom reader arg,
implemented by passing on to r4rs's load.

* r4rs.scm (load): Support an optional custom reader arg,
implemented by passing on to primitive-load.

* load.c (the_reader, the_reader_fluid_num): New.
(scm_primitive_load): Support custom reader.
(scm_init_load): Init the_reader and the_reader_fluid_num; export
the_reader as `current-reader'.
2005-12-14 00:21:11 +00:00
Neil Jerram
2824f4dca1 (do_read_without_guile): Use the "raw_data" passed in
(rather than an uninitialized pointer on the stack).
2005-12-14 00:15:00 +00:00
Marius Vollmer
6a88895b7b *** empty log message *** 2005-12-07 01:33:18 +00:00
Marius Vollmer
657e792903 (invoke_main_func): Don't call exit here. Throws that
are only caught by scm_with_guile will bypass us and would cause
scm_boot_guile to return erroneously.
(scm_boot_guile): Expect scm_with_guile to return and call exit
here, passing it an appropriate exit code.
2005-12-07 01:32:17 +00:00
Marius Vollmer
d9c36d2a6f (scm_find_executable): Compile fix -- fgetc returns an
unsigned char cast to an int, or -1 for EOS.
2005-12-06 22:35:05 +00:00
Marius Vollmer
08f489c98b *** empty log message *** 2005-12-06 21:42:43 +00:00
Marius Vollmer
ab7acbb74e (take_uvec): Make BASE pointer non-const.
(scm_take_u8vector, etc): Likewise.  Thanks to Ludovic Courtès!
2005-12-06 21:42:19 +00:00