1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-05-04 22:40:25 +02:00
Commit graph

5232 commits

Author SHA1 Message Date
Marius Vollmer
9511876f49 Include "libguile/goops.h". 2005-01-18 13:59:04 +00:00
Marius Vollmer
50472546d5 *** empty log message *** 2005-01-17 18:54:58 +00:00
Marius Vollmer
526982f570 * objects.h, objects.c (scm_classes_initialized): New.
(scm_class_of): Signal error when scm_classes_initialized is zero.
* goops.c (create_standard_classes): Set scm_classes_initialized
to one.
2005-01-17 18:11:43 +00:00
Marius Vollmer
009c6b9c89 *** empty log message *** 2005-01-17 17:22:33 +00:00
Marius Vollmer
f160e70907 (scm_random_solid_sphere_x): Use scm_c_generalized_vector_length
instead of scm_uniform_vector_length.
2005-01-17 17:22:22 +00:00
Marius Vollmer
7719cbe989 *** empty log message *** 2005-01-16 17:21:28 +00:00
Marius Vollmer
436be13ae8 (scm_compile_shell_switches): Removed debugging output. 2005-01-16 17:20:36 +00:00
Kevin Ryde
1ec44fed86 *** empty log message *** 2005-01-15 00:04:54 +00:00
Kevin Ryde
6efaeb3567 (scm_random_solid_sphere_x): Update docstring from manual. 2005-01-15 00:03:53 +00:00
Kevin Ryde
ba6e7231e4 (scm_logtest, scm_logbit_p, scm_integer_expt): Update
docstrings from manual.
2005-01-15 00:01:40 +00:00
Marius Vollmer
0b5a0521d1 *** empty log message *** 2005-01-14 18:27:12 +00:00
Marius Vollmer
00c17d4526 (scm_take_u64vector,
scm_array_handle_u64_elements,
scm_array_handle_u64_writable_elements, scm_u64vector_elements,
scm_u64vector_writable_elements): Do not define when scm_t_uint64
is not available.
(scm_take_s64vector, scm_array_handle_s64_elements,
scm_array_handle_s64_writable_elements, scm_s64vector_elements,
scm_s64vector_writable_elements): Likewise for scm_t_int64.
(uvec_sizes, uvec_print, uvec_equalp): Use SCM bignums when
scm_t_int64/scm_t_uint64 are not available.
(uvec_mark): New, to mark the bignums.
(alloc_uvec): Initialize bignums.
(uvec_fast_ref): Return bignums directly.
(scm_uint64_min, scm_uint64_max, scm_int64_min, scm_int64_max,
assert_exact_integer): New.
(uvec_fast_set): Use them to validate the bignums.
(scm_init_srfi_4): Set mark function of smob when needed.
Initialize scm_uint64_min, scm_uint64_max, scm_int64_min,
scm_int64_max.
2005-01-14 18:19:13 +00:00
Marius Vollmer
55fcbb966b Don't check for definedness of SCM_HAVE_T_INT64, check
its value.
2005-01-14 18:01:31 +00:00
Marius Vollmer
6e4cd850f6 *** empty log message *** 2005-01-14 16:24:17 +00:00
Marius Vollmer
39e707a130 (sym_at, sym_atat, sym_main, all_symbols): New.
(scm_compile_shell_switches): Use them to recognize and convert
1.4 "-e" syntax.
2005-01-14 16:20:36 +00:00
Marius Vollmer
3b698afe02 *** empty log message *** 2005-01-12 11:11:45 +00:00
Marius Vollmer
fe78c51aa2 Turn all deprecated features that once were macros but are now
functions back into macros.
2005-01-12 11:10:02 +00:00
Marius Vollmer
49086691f6 *** empty log message *** 2005-01-11 17:45:14 +00:00
Marius Vollmer
65bc1f7a0b * eval.c, debug.h (SCM_WARN_DEPRECATED): New debug option.
* deprecation.c (scm_issue_deprecation_warning,
scm_c_issue_deprecation_warning_fmt): Use it.
(mode): Removed.
(print_summary): New.
(scm_init_deprecation): Initialize SCM_WARN_DEPRECATED instead of
mode.
2005-01-11 17:43:37 +00:00
Marius Vollmer
d6dc83a9bc *** empty log message *** 2005-01-11 16:59:08 +00:00
Marius Vollmer
04b87de561 (SCM_ARRAYP, SCM_I_ARRAYP): Renamed former to latter internal
version.  Changed all uses.
(scm_tc16_array, scm_i_tc16_array,
scm_tc16_enclosed_array, scm_i_tc16_enclosed_array,
SCM_ARRAY_FLAG_CONTIGUOUS, SCM_I_ARRAY_FLAG_CONTIGUOUS,
SCM_ENCLOSE_ARRAYP, SCM_I_ENCLOSE_ARRAYP,
SCM_ARRAY_NDIM, SCM_I_ARRAY_NDIM,
SCM_ARRAY_CONTP, SCM_I_ARRAY_CONTP,
SCM_ARRAY_MEM, SCM_I_ARRAY_MEM,
SCM_ARRAY_V, SCM_I_ARRAY_V,
SCM_ARRAY_BASE, SCM_I_ARRAY_BASE,
SCM_ARRAY_DIMS, SCM_I_ARRAY_DIMS,
scm_t_array, scm_i_t_array): Likewise.
(SCM_SET_ARRAY_CONTIGUOUS_FLAG, SCM_CLR_ARRAY_CONTIGUOUS_FLAG):
Moved from unif.h to unif.c.
(scm_c_array_rank): New.
(scm_array_rank): Reimplement using it.
2005-01-11 16:55:38 +00:00
Marius Vollmer
1f366ef7f0 (SCM_ARRAYP, SCM_ARRAY_NDIM, SCM_ARRAY_CONTP, SCM_ARRAY_MEM,
SCM_ARRAY_V, SCM_ARRAY_BASE, SCM_ARRAY_DIMS, scm_t_array): New
deprecated versions.
2005-01-11 16:55:29 +00:00
Marius Vollmer
dc91d8de1a *** empty log message *** 2005-01-11 00:32:18 +00:00
Marius Vollmer
8551601218 Replace uses of scm_make_ra with scm_i_make_ra.
(GVREF, GVSET): New abbreviations.  Use them everywhere instead of
scm_c_generalized_vector_ref and scm_cvref, and
scm_c_generalized_vector_set_x, respectively.
(RVREF, IVDEP, BINARY_ELTS_CODE, BINARY_PAIR_ELTS_CODE,
UNARY_ELTS_CODE, UNARY_PAIR_ELTS_CODE): Removed since unused.
2005-01-11 00:31:06 +00:00
Marius Vollmer
0cd6cb2fb2 (indices_to_pos, scm_array_handle_pos): Renamed
former to latter and made public.  Changed all uses.
(scm_i_make_ra): Made public, changed tag param to enclosed flag.
(scm_make_ra): Deprecated, changed all uses to scm_i_make_ra.
(scm_i_shap2ra): New internal version of scm_shap2ra.
(scm_shap2ra): Deprecated, changed all uses to scm_i_shap2ra.
(scm_i_ra_set_contp): New internal version of scm_ra_set_contp.
(scm_ra_set_contp): Deprecated, changed all uses to
scm_i_ra_set_contp.
(scm_cvref, scm_aind, scm_raprin1): Deprecated.
2005-01-11 00:26:23 +00:00
Marius Vollmer
b06f099d1d *** empty log message *** 2005-01-10 20:21:19 +00:00
Marius Vollmer
6be1fab900 (scm_eval): Added example to docstring. Thanks to Issac Trotts! 2005-01-10 20:20:58 +00:00
Marius Vollmer
5d35ad8187 *** empty log message *** 2005-01-10 19:07:02 +00:00
Marius Vollmer
2caaadd1c2 (scm_list_to_typed_array): Allow the specification of the
upper bound as well.  This is needed for empty arrays.
(l2ra): Give needed number of elements in error message.
(scm_i_print_array): Print length information for arrays that need
it.
(scm_i_read_array): Parse it.
2005-01-10 19:06:48 +00:00
Marius Vollmer
66d3378432 *** empty log message *** 2005-01-10 17:42:33 +00:00
Marius Vollmer
a725fa951c (SCM_CHARS, SCM_UCHARS, SCM_LENGTH, scm_i_object_chars,
scm_i_object_length): Brought back from the dead.
2005-01-10 17:42:23 +00:00
Marius Vollmer
74c58fce0f *** empty log message *** 2005-01-10 01:45:07 +00:00
Marius Vollmer
afaf9d0b01 Replaced single-index uses of scm_array_set_x with
scm_c_generalized_vector_set_x.
2005-01-10 01:42:29 +00:00
Marius Vollmer
112ba0ac28 (scm_make_shared_array): Use it instead of scm_aind; use handle
for oldra.
2005-01-10 01:41:35 +00:00
Kevin Ryde
d3ddc95ef1 *** empty log message *** 2005-01-10 00:32:48 +00:00
Marius Vollmer
d7d7d40166 *** empty log message *** 2005-01-10 00:20:56 +00:00
Marius Vollmer
523727193a (scm_array_rank, scm_array_dimensions,
scm_shared_array_offset, scm_shared_array_increments,
scm_array_ref, scm_array_set_x): Use scm_t_array_handle operations
to simplify code and make it more general.
(scm_shared_array_root): Work with all kinds of arrays, including
naked vectors.
(indices_to_pos): New.
2005-01-10 00:15:48 +00:00
Kevin Ryde
fa0198bfad (scm_mktime): Missing default errno=EINVAL from prev change. 2005-01-10 00:11:25 +00:00
Marius Vollmer
8cb01d9fbf *** empty log message *** 2005-01-09 22:38:39 +00:00
Marius Vollmer
4e8ad32394 (coerce_to_uvec, scm_c_uniform_vector_ref,
scm_c_uniform_vector_set_x): Use generic scm_array_handle_ref/set
instead of uvec_fast_ref/set since scm_array_handle_ref should be
faster now.
2005-01-09 22:37:50 +00:00
Kevin Ryde
4475d3febd *** empty log message *** 2005-01-09 22:31:53 +00:00
Kevin Ryde
2c4cdcb06c (scm_mkstemp): Update docstring from manual. 2005-01-09 22:23:14 +00:00
Marius Vollmer
b89ecc6fb3 *** empty log message *** 2005-01-09 22:12:26 +00:00
Marius Vollmer
4ea4bc4c40 * srfi-4.h, srfi-4.c, srfi-4.i.c (scm_i_uniform_vector_ref_proc,
scm_i_uniform_vector_set_proc): New.
(u8ref, u8set, s8ref, s8set, etc): New.
(uvec_reffers, uvec_setters): New.
(uvec_to_list): Use generic scm_array_handle_ref instead of
uvec_fast_ref since scm_array_handle_ref should be faster now.
More changes like this are upcoming.
2005-01-09 22:06:56 +00:00
Marius Vollmer
9598a4060a * unif.h, unif.c, inline.h (scm_i_t_array_ref, scm_i_t_array_set):
New.
(scm_t_array_handle): Added ref, set, elements and
writable_elements for fast inline operation of
scm_array_handle_ref and scm_array_handle_set.
(scm_array_handle_ref, scm_array_handle_set): Moved to inline.h
and replaced with inline code that simply calls the ref/set
members of the handle.
(enclosed_ref, vector_ref, string_ref, bitvector_ref, memoize_ref,
enclosed_set, vector_set, string_set, bitvector_set, memoize_set):
New.
(scm_array_handle_get): Initialize ref/set fields to memoize_ref
and memoize_set.
(scm_bitvector_fill_x, scm_bitvector_to_list, scm_bit_count,
scm_bit_position, scm_bit_set_star_x, scm_bit_count_star,
scm_bit_invert_x): Correctly multiply index with increment in the
general case.

* unif.c (scm_array_handle_set): Correctly execute only one
alternative.  D'Oh!
(scm_list_to_typed_array, l2ra): Use scm_t_array_handle to fill
the array; this covers all cases with much simpler code.
2005-01-09 22:02:40 +00:00
Marius Vollmer
8c8491f56c *** empty log message *** 2005-01-09 17:47:36 +00:00
Marius Vollmer
bcbbea0e2f (scm_array_handle_set): Correctly execute only one
alternative.  D'Oh!
(scm_list_to_typed_array, l2ra): Use scm_t_array_handle to fill
the array; this covers all cases with much simpler code.
2005-01-09 17:45:59 +00:00
Marius Vollmer
7c2ef9a87b (scm_uniform_element_size): Deprecated implementation
as well.
2005-01-09 17:43:14 +00:00
Marius Vollmer
cd5d55c76c *** empty log message *** 2005-01-09 15:45:33 +00:00
Marius Vollmer
5e320e5926 (uvec_type): New.
(uvec_to_list, uvec_ref, uvec_set_x, scm_c_uniform_vector_ref,
scm_c_uniform_vector_x): Use it to get concrete type.
2005-01-09 15:45:21 +00:00