From d550e35f379fccfacedf8676117338adeeb7fc3c Mon Sep 17 00:00:00 2001 From: Marius Vollmer Date: Fri, 12 Nov 2004 19:00:36 +0000 Subject: [PATCH] *** empty log message *** --- ice-9/ChangeLog | 4 ++++ libguile/ChangeLog | 48 +++++++++++++++++++++++++++++++++++++++++++- test-suite/ChangeLog | 6 ++++++ 3 files changed, 57 insertions(+), 1 deletion(-) diff --git a/ice-9/ChangeLog b/ice-9/ChangeLog index b53b3e907..4c7f03857 100644 --- a/ice-9/ChangeLog +++ b/ice-9/ChangeLog @@ -1,3 +1,7 @@ +2004-11-12 Marius Vollmer + + * arrays.scm: Do not use prototypes, use creator functions. + 2004-11-10 Marius Vollmer * arrays.scm (uniform-vector-read!, uniform-vector-write): diff --git a/libguile/ChangeLog b/libguile/ChangeLog index 73f2e8d8a..1fefbac36 100644 --- a/libguile/ChangeLog +++ b/libguile/ChangeLog @@ -1,9 +1,55 @@ +2004-11-12 Marius Vollmer + + Enclosed arrays are now their own smob. This has been done to + make the code more explicit about them and to prepare for the time + when generalized vectors include arbitrary one-dimensional arrays. + + * unif.h, unif.c: (scm_tc16_enclosed_array, SCM_ENCLOSED_ARRAYP): + New. + (exactly_one_third, singp): Removed. + (scm_array_p, scm_array_dimensions, scm_shared_array_root, + scm_shared_array_offset, scm_shared_array_increments): Handle + enclosed arrays explicitely. + (scm_array_rank): Likewise. Also, do not return zero for + non-arrays, signal an error instead since arrays with rank zero do + exist. + (scm_i_make_ra): New, for specifying the tag of the new array. + (scm_make_enclosed_array): Use it. + (scm_make_ra): Reimplemented in terms of scm_i_make_ra. + (scm_make_shared_array): Use scm_c_generalized_vector_length + instead of scm_uniform_vector_length. + (scm_array_in_bounds_p): Rewritten to be much cleaner. + (scm_i_cvref): New, doing the job of scm_cvref. + (scm_cvref): Use scm_i_cvref. + (scm_array_ref): Do not accept non-arrays when no indices are + given. Use scm_i_cvref to do the actual access. + ("uniform-array-set1"): Do not register. + (scm_array_set_x, scm_uniform_array_read_x, + scm_uniform_array_write): Handle enclosed arrays explicitly. + (ra2l): Use scm_i_cvref instead of scm_uniform_vector_ref to also + handle enclosed arrays. + (scm_array_to_list): Handle enclosed arrays explicitly. + (rapr1): Removed. + (scm_i_print_array_dimension): Use scm_i_cvref to also handle + enclosed arrays. + (scm_i_print_enclosed_array): New. + (tag_proto_table, tag_creator_table): Renamed former to latter. + Added "a" and "b" for strings and bitvectors, resp. + (scm_i_tag_to_prototype, scm_i_tag_to_creator): Renamed former to + latter. Tag "a" is in the table now, no need to handle it as a + legacy tag. + (scm_raprin1): Just call scm_iprin1. + (scm_array_creator, scm_array_prototype): Handle enclosed arrays + explicitly. + (scm_init_unif): Initialize scm_tc16_enclosed_array smob. + Use scm_i_print_array as printer for scm_tc16_array. + 2004-11-10 Marius Vollmer * ramap.c (cind): Changed second arg to be pointer to long instead of uniform vector. (scm_ramapc): Allocate index vector with scm_malloc and not as - uniform vector. Wrap it in a frameso that it gets properly freed. + uniform vector. Wrap it in a frame so that it gets properly freed. (scm_array_index_map_x): Likewise. * unif.c: Changed all uses of scm_array_prototype to diff --git a/test-suite/ChangeLog b/test-suite/ChangeLog index d14bb8ee6..f16123793 100644 --- a/test-suite/ChangeLog +++ b/test-suite/ChangeLog @@ -1,3 +1,9 @@ +2004-11-12 Marius Vollmer + + * tests/unif.test: Replaced uniform-array-set1! with just + array-set!. Do not check improper index lists, which can't arise + with uarray-set!. Use "#s16()" instead of "#h()". + 2004-10-27 Marius Vollmer * tests/unif.test: Removed tests that tried to store a character