Commit | Line | Data |
---|---|---|
88f59e53 MV |
1 | 2005-01-20 Marius Vollmer <marius.vollmer@uni-dortmund.de> |
2 | ||
3 | * objects.c: Include goops.h for the scm_class_of prototype. | |
4 | ||
5 | * hashtab.c (hashtable_size, HASHTABLE_SIZE_N): Restrict hashtable | |
6 | sizes to be smaller than the maximum lengths of vectors. | |
7 | ||
219b2868 MV |
8 | 2005-01-18 Marius Vollmer <marius.vollmer@uni-dortmund.de> |
9 | ||
10 | * ports.c, smob.c: Include "libguile/goops.h". | |
11 | ||
12 | * objects.h, objects.c, goops.c, goops.h (scm_class_boolean, | |
13 | scm_class_char, scm_class_pair, scm_class_procedure, | |
14 | scm_class_string, scm_class_symbol, | |
15 | scm_class_procedure_with_setter, scm_class_primitive_generic, | |
16 | scm_class_vector, scm_class_null, scm_class_real, | |
17 | scm_class_complex, scm_class_integer, scm_class_fraction, | |
18 | scm_class_unknown, scm_port_class, scm_smob_class, | |
19 | scm_no_applicable_method, scm_class_of): Moved from objects to | |
20 | goops since they are only useable once goops has been loaded. | |
21 | (scm_classes_initialized): Removed. | |
22 | (scm_class_of): Do not check it. | |
23 | (create_standard_classes): Do not set it. | |
24 | ||
009c6b9c MV |
25 | 2005-01-17 Marius Vollmer <marius.vollmer@uni-dortmund.de> |
26 | ||
50472546 MV |
27 | * objects.h, objects.c (scm_classes_initialized): New. |
28 | (scm_class_of): Signal error when scm_classes_initialized is zero. | |
29 | * goops.c (create_standard_classes): Set scm_classes_initialized | |
30 | to one. | |
31 | ||
009c6b9c MV |
32 | * random.c (scm_random_solid_sphere_x): Use |
33 | scm_c_generalized_vector_length instead of | |
34 | scm_uniform_vector_length. | |
35 | ||
7719cbe9 MV |
36 | 2005-01-16 Marius Vollmer <mvo@zagadka.de> |
37 | ||
38 | * script.c (scm_compile_shell_switches): Removed debugging output. | |
39 | ||
1ec44fed KR |
40 | 2005-01-15 Kevin Ryde <user42@zip.com.au> |
41 | ||
42 | * numbers.c (scm_logtest, scm_logbit_p, scm_integer_expt): Update | |
43 | docstrings from manual. | |
44 | * random.c (scm_random_solid_sphere_x): Update docstring from manual. | |
45 | ||
6e4cd850 MV |
46 | 2005-01-14 Marius Vollmer <marius.vollmer@uni-dortmund.de> |
47 | ||
0b5a0521 MV |
48 | * random.c: Don't check for definedness of SCM_HAVE_T_INT64, check |
49 | its value. | |
50 | ||
51 | Implement u64 and s64 uniform numeric vectors with bignums when | |
52 | scm_t_uint64 and scm_t_int64 are not available. | |
53 | ||
54 | * srfi-4.h, srfi-4.c, srfi-4.i.c (scm_take_u64vector, | |
55 | scm_array_handle_u64_elements, | |
56 | scm_array_handle_u64_writable_elements, scm_u64vector_elements, | |
57 | scm_u64vector_writable_elements): Do not define when scm_t_uint64 | |
58 | is not available. | |
59 | (scm_take_s64vector, scm_array_handle_s64_elements, | |
60 | scm_array_handle_s64_writable_elements, scm_s64vector_elements, | |
61 | scm_s64vector_writable_elements): Likewise for scm_t_int64. | |
62 | (uvec_sizes, uvec_print, uvec_equalp): Use SCM bignums when | |
63 | scm_t_int64/scm_t_uint64 are not available. | |
64 | (uvec_mark): New, to mark the bignums. | |
65 | (alloc_uvec): Initialize bignums. | |
66 | (uvec_fast_ref): Return bignums directly. | |
67 | (scm_uint64_min, scm_uint64_max, scm_int64_min, scm_int64_max, | |
68 | assert_exact_integer): New. | |
69 | (uvec_fast_set): Use them to validate the bignums. | |
70 | (scm_init_srfi_4): Set mark function of smob when needed. | |
71 | Initialize scm_uint64_min, scm_uint64_max, scm_int64_min, | |
72 | scm_int64_max. | |
73 | ||
6e4cd850 MV |
74 | Recognize 1.4 -e syntax. |
75 | ||
76 | * script.c (sym_at, sym_atat, sym_main, all_symbols): New. | |
77 | (scm_compile_shell_switches): Use them to recognize and convert | |
78 | 1.4 "-e" syntax. | |
79 | ||
3b698afe MV |
80 | 2005-01-12 Marius Vollmer <marius.vollmer@uni-dortmund.de> |
81 | ||
82 | * deprecated.h, deprecated.c, strings.h, strings.c: Turn all | |
83 | deprecated features that once were macros but are now functions | |
84 | back into macros. | |
85 | ||
d6dc83a9 MV |
86 | 2005-01-11 Marius Vollmer <marius.vollmer@uni-dortmund.de> |
87 | ||
49086691 MV |
88 | * eval.c, debug.h (SCM_WARN_DEPRECATED): New debug option. |
89 | * deprecation.c (scm_issue_deprecation_warning, | |
90 | scm_c_issue_deprecation_warning_fmt): Use it. | |
91 | (mode): Removed. | |
92 | (print_summary): New. | |
93 | (scm_init_deprecation): Initialize SCM_WARN_DEPRECATED instead of | |
94 | mode. | |
95 | ||
d6dc83a9 MV |
96 | Deprecated SCM_ARRAY* macros. |
97 | ||
98 | * unif.h, unif.c, ramap.c, vectors.c, srfi-4.c, srfi-4.i.c | |
99 | (SCM_ARRAYP, SCM_I_ARRAYP): Renamed former to latter internal | |
100 | version. Changed all uses. | |
101 | (scm_tc16_array, scm_i_tc16_array, | |
102 | scm_tc16_enclosed_array, scm_i_tc16_enclosed_array, | |
103 | SCM_ARRAY_FLAG_CONTIGUOUS, SCM_I_ARRAY_FLAG_CONTIGUOUS, | |
104 | SCM_ENCLOSE_ARRAYP, SCM_I_ENCLOSE_ARRAYP, | |
105 | SCM_ARRAY_NDIM, SCM_I_ARRAY_NDIM, | |
106 | SCM_ARRAY_CONTP, SCM_I_ARRAY_CONTP, | |
107 | SCM_ARRAY_MEM, SCM_I_ARRAY_MEM, | |
108 | SCM_ARRAY_V, SCM_I_ARRAY_V, | |
109 | SCM_ARRAY_BASE, SCM_I_ARRAY_BASE, | |
110 | SCM_ARRAY_DIMS, SCM_I_ARRAY_DIMS, | |
111 | scm_t_array, scm_i_t_array): Likewise. | |
112 | (SCM_SET_ARRAY_CONTIGUOUS_FLAG, SCM_CLR_ARRAY_CONTIGUOUS_FLAG): | |
113 | Moved from unif.h to unif.c. | |
114 | (scm_c_array_rank): New. | |
115 | (scm_array_rank): Reimplement using it. | |
116 | ||
117 | * deprecated.h, deprecated.c (SCM_ARRAYP, SCM_ARRAY_NDIM, | |
118 | SCM_ARRAY_CONTP, SCM_ARRAY_MEM, SCM_ARRAY_V, SCM_ARRAY_BASE, | |
119 | SCM_ARRAY_DIMS, scm_t_array): New deprecated versions. | |
120 | ||
dc91d8de MV |
121 | 2005-01-11 Marius Vollmer <mvo@zagadka.de> |
122 | ||
123 | * ramap.c: Replace uses of scm_make_ra with scm_i_make_ra. | |
124 | (GVREF, GVSET): New abbreviations. Use them everywhere instead of | |
125 | scm_c_generalized_vector_ref and scm_cvref, and | |
126 | scm_c_generalized_vector_set_x, respectively. | |
127 | (RVREF, IVDEP, BINARY_ELTS_CODE, BINARY_PAIR_ELTS_CODE, | |
128 | UNARY_ELTS_CODE, UNARY_PAIR_ELTS_CODE): Removed since unused. | |
129 | ||
130 | * unif.h, unif.c (indices_to_pos, scm_array_handle_pos): Renamed | |
131 | former to latter and made public. Changed all uses. | |
132 | (scm_i_make_ra): Made public, changed tag param to enclosed flag. | |
133 | (scm_make_ra): Deprecated, changed all uses to scm_i_make_ra. | |
134 | (scm_i_shap2ra): New internal version of scm_shap2ra. | |
135 | (scm_shap2ra): Deprecated, changed all uses to scm_i_shap2ra. | |
136 | (scm_i_ra_set_contp): New internal version of scm_ra_set_contp. | |
137 | (scm_ra_set_contp): Deprecated, changed all uses to | |
138 | scm_i_ra_set_contp. | |
139 | (scm_cvref, scm_aind, scm_raprin1): Deprecated. | |
140 | ||
66d33784 MV |
141 | 2005-01-10 Marius Vollmer <marius.vollmer@uni-dortmund.de> |
142 | ||
b06f099d MV |
143 | * eval.c (scm_eval): Added example to docstring. Thanks to Issac |
144 | Trotts! | |
145 | ||
5d35ad81 MV |
146 | * unif.c (scm_list_to_typed_array): Allow the specification of the |
147 | upper bound as well. This is needed for empty arrays. | |
148 | (l2ra): Give needed number of elements in error message. | |
149 | (scm_i_print_array): Print length information for arrays that need | |
150 | it. | |
151 | (scm_i_read_array): Parse it. | |
152 | ||
66d33784 MV |
153 | * deprecated.h, deprecated.c (SCM_CHARS, SCM_UCHARS, SCM_LENGTH, |
154 | scm_i_object_chars, scm_i_object_length): Brought back from the | |
155 | dead. | |
156 | ||
d7d7d401 MV |
157 | 2005-01-10 Marius Vollmer <mvo@zagadka.de> |
158 | ||
74c58fce MV |
159 | * ramap.c: Replaced single-index uses of scm_array_set_x with |
160 | scm_c_generalized_vector_set_x. | |
161 | ||
d7d7d401 MV |
162 | * unif.c (scm_array_rank, scm_array_dimensions, |
163 | scm_shared_array_offset, scm_shared_array_increments, | |
164 | scm_array_ref, scm_array_set_x): Use scm_t_array_handle operations | |
165 | to simplify code and make it more general. | |
166 | (scm_shared_array_root): Work with all kinds of arrays, including | |
167 | naked vectors. | |
168 | (indices_to_pos): New. | |
74c58fce MV |
169 | (scm_make_shared_array): Use it instead of scm_aind; use handle |
170 | for oldra. | |
171 | ||
4475d3fe KR |
172 | 2005-01-10 Kevin Ryde <user42@zip.com.au> |
173 | ||
174 | * posix.c (scm_mkstemp): Update docstring from manual. | |
175 | ||
d3ddc95e KR |
176 | * stime.c (scm_mktime): Missing default errno=EINVAL from prev change. |
177 | ||
8c8491f5 MV |
178 | 2005-01-09 Marius Vollmer <mvo@zagadka.de> |
179 | ||
b89ecc6f MV |
180 | * srfi-4.h, srfi-4.c, srfi-4.i.c (scm_i_uniform_vector_ref_proc, |
181 | scm_i_uniform_vector_set_proc): New. | |
182 | (u8ref, u8set, s8ref, s8set, etc): New. | |
183 | (uvec_reffers, uvec_setters): New. | |
184 | (uvec_to_list): Use generic scm_array_handle_ref instead of | |
185 | uvec_fast_ref since scm_array_handle_ref should be faster now. | |
8cb01d9f MV |
186 | (coerce_to_uvec, scm_c_uniform_vector_ref, |
187 | scm_c_uniform_vector_set_x): Likewise. | |
b89ecc6f MV |
188 | |
189 | * unif.h, unif.c, inline.h (scm_i_t_array_ref, scm_i_t_array_set): | |
190 | New. | |
191 | (scm_t_array_handle): Added ref, set, elements and | |
192 | writable_elements for fast inline operation of | |
193 | scm_array_handle_ref and scm_array_handle_set. | |
194 | (scm_array_handle_ref, scm_array_handle_set): Moved to inline.h | |
195 | and replaced with inline code that simply calls the ref/set | |
196 | members of the handle. | |
197 | (enclosed_ref, vector_ref, string_ref, bitvector_ref, memoize_ref, | |
198 | enclosed_set, vector_set, string_set, bitvector_set, memoize_set): | |
199 | New. | |
200 | (scm_array_handle_get): Initialize ref/set fields to memoize_ref | |
201 | and memoize_set. | |
202 | (scm_bitvector_fill_x, scm_bitvector_to_list, scm_bit_count, | |
203 | scm_bit_position, scm_bit_set_star_x, scm_bit_count_star, | |
204 | scm_bit_invert_x): Correctly multiply index with increment in the | |
205 | general case. | |
206 | ||
8c8491f5 MV |
207 | * unif.c (scm_array_handle_set): Correctly execute only one |
208 | alternative. D'Oh! | |
209 | (scm_list_to_typed_array, l2ra): Use scm_t_array_handle to fill | |
210 | the array; this covers all cases with much simpler code. | |
211 | ||
212 | * srfi-4.c (scm_uniform_element_size): Deprecated implementation | |
213 | as well. | |
214 | ||
cd5d55c7 MV |
215 | 2005-01-09 Marius Vollmer <marius.vollmer@uni-dortmund.de> |
216 | ||
217 | * srfi-4.c (uvec_type): New. | |
218 | (uvec_to_list, uvec_ref, uvec_set_x, scm_c_uniform_vector_ref, | |
219 | scm_c_uniform_vector_x): Use it to get concrete type. | |
220 | ||
221 | * unif.h (scm_t_array_dim): Changed type of members to ssize_t, to | |
222 | fit the docs. | |
223 | ||
224 | * unif.c (ra2l): Handle zero rank arrays. | |
225 | (scm_i_print_array): Print zero rank arrays specially. | |
226 | (tag_to_type): Return #t for an empty tag, not the empty symbol. | |
227 | (scm_i_read_array): Allow zero rank arrays. | |
228 | ||
a4aad74e MV |
229 | 2005-01-07 Marius Vollmer <marius.vollmer@uni-dortmund.de> |
230 | ||
231 | * hashtab.h, hashtab.c (SCM_HASHTAB_BUCKET_LOC): Removed. | |
232 | (scan_weak_hashtables): Rewrote its use with SCM_HASHTAB_BUCKET | |
233 | and SCM_SET_HASHTAB_BUCKET. | |
234 | ||
235 | * print.h, print.c (scm_print_state, SCM_PRINT_STATE_LAYOUT): | |
236 | Removed ref_stack field. | |
237 | (PSTATE_STACK_REF, PSTATE_STACK_SET): New, for accessing the stack | |
238 | of a print state. Use them everywhere instead of ref_stack. | |
239 | ||
3a40d5e1 MV |
240 | * srfi-4.h (scm_uniform_element_size): Deprecated for real. |
241 | ||
a4aad74e MV |
242 | * srfi-4.c: Include deprecation.h. |
243 | ||
244 | * vectors.h, vectors.c, unif.h, unif.c, deprecated.h, | |
245 | deprecated.c, eq.c | |
246 | (SCM_BITVEC_REF, SCM_BITVEC_SET, SCM_BITVEC_CLR): Removed. | |
247 | (scm_vector_elements, scm_vector_writable_elements, | |
248 | scm_generalized_vector_get_handle): Moved to vectors.[hc] from | |
249 | unif.[hc]. | |
250 | (SCM_SIMPLE_VECTOR_LOC): Removed. | |
251 | (SCM_VECTOR_MAX_LENGTH, SCM_VECTOR_LENGTH, SCM_VELTS, | |
252 | SCM_WRITABLE_VELTS, SCM_VECTOR_REF, SCM_VECTOR_SET, | |
253 | scm_vector_equal_p): Moved from vectors.[hc] to deprecated.[hc]. | |
254 | (scm_vector_equal_p, scm_i_vector_equal_p): Renamed former to | |
255 | latter. Changed use in eq.c. | |
256 | ||
f01fe441 MV |
257 | 2005-01-07 Marius Vollmer <mvo@zagadka.de> |
258 | ||
259 | Make the uniform vector routines also deal with one dimensional | |
260 | arrays. | |
261 | ||
262 | * srfi-4.c (SCM_IS_UVEC): New, use it instead of | |
263 | SCM_SMOB_PREDICATE in this file. | |
264 | (is_uvec): Also recognize one-dimensional uniform numeric arrays | |
265 | of the right type. | |
266 | (scm_is_uniform_vector): Likewise. | |
267 | (uvec_fast_ref): Made BASE param const. | |
268 | (uvec_writable_elements, uvec_elements): New. | |
269 | (uvec_to_list, uvec_ref, uvec_set_x, uvec_length, | |
270 | scm_c_uniform_vector_length, scm_c_uniform_vector_ref, | |
271 | scm_c_uniform_set_x): Use them to also deal with one-dimensional | |
272 | arrays. | |
273 | (scm_uniform_vector_ref, scm_uniform_vector_set_x): Deprecate old | |
274 | argument convention. | |
275 | (scm_uniform_vector_to_list): Let uvec_to_list do all the | |
276 | checking. | |
277 | (scm_uniform_vector_length): Use uvec_length. | |
278 | ||
2aaf5726 MV |
279 | 2005-01-06 Marius Vollmer <marius.vollmer@uni-dortmund.de> |
280 | ||
281 | * srfi-4.h, srfi-4.c (scm_c_uniform_vector_element_size, | |
282 | scm_c_uniform_vector_size): Removed. | |
283 | (scm_array_handle_uniform_element_size): New. | |
284 | ||
285 | ||
286 | * unif.h (scm_array_handle_ref, scm_array_handle_set): Changed | |
287 | type of POS parameter to be signed, positions can be negative. | |
288 | (scm_array_handle_release): New, changed all uses of | |
289 | scm_t_array_handle to properly call it. | |
290 | (scm_vector_get_handle, scm_generalized_vector_get_handle): | |
291 | Renamed former to latter, changed all uses. | |
292 | ||
34ae52fc MV |
293 | 2005-01-05 Marius Vollmer <mvo@zagadka.de> |
294 | ||
295 | Updated bitvector routines to also use scm_t_array_handles. | |
296 | ||
297 | * unif.h (scm_bitvector_elements, | |
298 | scm_bitvector_writable_elements): Use a scm_t_array_handle and | |
299 | deliver offset, length and increment to caller. Changed all uses. | |
300 | (scm_bitvector_release_elements, | |
301 | scm_frame_bitvector_release_elements, | |
302 | scm_bitvector_release_writable_elements, | |
303 | scm_frame_bitvector_release_writable_elements): Removed. | |
304 | (scm_array_handle_bit_elements, | |
305 | scm_array_handle_bit_writable_elements, | |
306 | scm_array_handle_bit_elements_offset): New. | |
307 | (scm_make_typed_array): The special value for non-initialized | |
308 | arrays is now SCM_UNSPECIFIED. The old special value SCM_BOOL_F | |
309 | was a valid value to fill bitvectors with, so it can't really be | |
310 | specialed out. | |
311 | ||
c4cb7628 KR |
312 | 2005-01-04 Kevin Ryde <user42@zip.com.au> |
313 | ||
314 | * stime.c (scm_strftime): Free t.tm_zone produced by bdtime2c. | |
315 | Reported by Bill Schottstaedt. | |
316 | ||
0356881d MV |
317 | 2005-01-02 Marius Vollmer <mvo@zagadka.de> |
318 | ||
319 | * sort.c (quicksort): Added INC parameter for non-contigous | |
320 | vectors. | |
321 | (quicksort1): New, for contigous vectors. Both functions are | |
322 | generated from the same code by including "quicksort.i.c". | |
323 | (scm_restricted_vector_sort_x): Call one of quicksort and | |
324 | quicksort1, depending on increment of vector. | |
325 | (scm_sort): Simply call scm_sort_x on a copy of the list or | |
326 | vector. | |
327 | (scm_merge_vector_x, scm_merge_vector_step): Changed indices to | |
328 | size_t, added inc parameter. | |
329 | (scm_stable_sort_x): Allocate temporary storage as Scheme vector | |
330 | so that it doesn't leak. | |
331 | (scm_stable_sort): Simply call scm_stable_sort_x on a copy of the | |
332 | list or vector. | |
333 | ||
334 | * ramap.c (scm_array_map_x): Do not try to convert fill value | |
335 | before filling, any necessary conversion is done while storing. | |
336 | ||
337 | * gc-card.c (scm_i_sweep_card): Call scm_i_vector_free instead of | |
338 | doing it inline. | |
339 | ||
340 | * hashtab.c, hashtab.h (SCM_HASHTABLE_BUCKETS): Removed. | |
341 | (SCM_HASHTABLE_BUCKET, SCM_HASHTABLE_BUCKET_LOC): New. Replaced | |
342 | all uses of SCM_HASHTABLE_BUCKETS with SCM_HASHTABLE_BUCKET. | |
343 | ||
344 | * tags.h, weaks.c, vports.c, hashtab.c, convert.c, sort.c, | |
345 | convert.c, convert.h, convert.i.c, deprecated.c, environments.c, | |
346 | eval.c, filesys.c, fluids.c, gc-mark.c, gh.h, gh_data.c, goops.c, | |
347 | hash.c, init.c, libguile_la-arrays.loT, modules.c, net_db.c, | |
348 | objects.c, ports.c, posix.c, print.c, random.c, read.c, | |
349 | regex-posix.c, scmsigs.c, socket.c, stime.c, symbols.c: Use new | |
350 | vector elements API or simple vector API, as appropriate. Removed | |
351 | SCM_HAVE_ARRAYS ifdefery. Replaced all uses of | |
352 | SCM_HASHTABLE_BUCKETS with SCM_HASHTABLE_BUCKET. | |
353 | ||
354 | * srfi-4.h, srfi-4.c, | |
355 | srfi-4.i.c (scm_array_handle_uniform_elements, | |
356 | scm_array_handle_uniform_writable_elements, | |
357 | scm_uniform_vector_elements, | |
358 | scm_uniform_vector_writable_elements): | |
359 | (scm_<foo>vector_elements, scm_<foo>vector_writable_elements): Use | |
360 | scm_t_array_handle, deliver length and increment. | |
361 | (scm_array_handle_<foo>_elements, | |
362 | scm_array_handle_<foo>_writable_elements): New. | |
363 | ||
364 | * gen-scmconfig.h.in (SCM_I_GSC_HAVE_ARRAYS): Removed. | |
365 | * gen-scmconfig.c: Hard code SCM_HAVE_ARRAYS to "1". | |
366 | ||
367 | * unif.h, unif.c (scm_t_array_handle, scm_array_get_handle, | |
368 | scm_array_handle_rank, scm_array_handle_dims, scm_array_handle_ref | |
369 | scm_array_handle_set, scm_array_handle_elements | |
370 | scm_array_handle_writable_elements, scm_vector_get_handle): New. | |
371 | (scm_make_uve, scm_array_prototype, scm_list_to_uniform_array, | |
372 | scm_dimensions_to_uniform_array): Deprecated for real. | |
373 | (scm_array_p, scm_i_array_p): Use latter for SCM_DEFINE since | |
374 | snarfing wont allow a mismatch between C and Scheme arglists. | |
375 | (scm_make_shared_array, scm_enclose_array): Correctly use | |
376 | scm_c_generalized_vector_length instead of | |
377 | scm_uniform_vector_length. | |
378 | ||
379 | * validate.h (SCM_VALIDATE_VECTOR, | |
380 | SCM_VALIDATE_VECTOR_OR_DVECTOR): use scm_is_simple_vector instead | |
381 | of SCM_VECTORP. | |
382 | ||
383 | * weaks.h, weaks.c: Use new internal weak vector API from | |
384 | vectors.h. | |
385 | ||
386 | * Makefile.am (libguile_la_SOURCES, DOT_X_FILES, DOT_DOC_FILES, | |
387 | EXTRA_libguile_la_SOURCES): Changed ramap.c and unif.c from being | |
388 | 'extra' to being regular sources. | |
389 | (noinst_HEADERS): Added quicksort.i.c. | |
390 | * quicksort.i.c: New file. | |
391 | ||
392 | * vectors.h, vector.c (SCM_VECTORP, SCM_VECTOR_LENGTH, SCM_VELTS, | |
393 | SCM_WRITABLE_VELTS, SCM_VECTOR_REF, SCM_VECTOR_SET): Deprecated | |
394 | and reimplemented. Replaced all uses with scm_vector_elements, | |
395 | scm_vector_writable_elements, or SCM_SIMPLE_VECTOR_*, as | |
396 | appropriate. | |
397 | (scm_is_simple_vector, SCM_SIMPLE_VECTOR_LENGTH, | |
398 | SCM_SIMPLE_VECTOR_REF, SCM_SIMPLE_VECTOR_SET, | |
399 | SCM_SIMPLE_VECTOR_LOC): New. | |
400 | (SCM_VECTOR_BASE, SCM_SET_VECTOR_BASE, SCM_VECTOR_MAX_LENGTH, | |
401 | SCM_MAKE_VECTOR_TAG, SCM_SET_VECTOR_LENGTH, | |
402 | SCM_VELTS_AS_STACKITEMS, SCM_SETVELTS, SCM_GC_WRITABLE_VELTS): | |
403 | Removed. | |
404 | (scm_vector_copy): New. | |
405 | (scm_vector_elements, scm_vector_writable_elements): Use | |
406 | scm_t_array_handle, deliver length and increment. Moved to | |
407 | unif.h. Changed all uses. | |
408 | (scm_vector_release_elements, | |
409 | scm_vector_release_writable_elements, | |
410 | (scm_frame_vector_release_elements, | |
411 | scm_frame_vector_release_writable_elements): Removed. | |
412 | (SCM_I_IS_VECTOR, SCM_I_VECTOR_ELTS, SCM_I_VECTOR_WELTS, | |
413 | SCM_I_VECTOR_LENGTH, scm_i_vector_free): New internal API. | |
414 | (SCM_I_WVECTP SCM_I_WVECT_LENGTH SCM_I_WVECT_VELTS | |
415 | SCM_I_WVECT_GC_WVELTS SCM_I_WVECT_TYPE SCM_I_WVECT_GC_CHAIN | |
416 | SCM_I_SET_WVECT_GC_CHAIN, scm_i_allocate_weak_vector): New, for | |
417 | weak vectors. | |
418 | ||
0336d18b MV |
419 | 2004-12-29 Marius Vollmer <mvo@zagadka.de> |
420 | ||
421 | No longer use creators to specify the type of an array. Creators | |
422 | expose the fact that arrays are wrapped around vectors, but that | |
423 | might change. | |
424 | ||
425 | * srfi-4.h (scm_i_proc_make_u8vector, scm_i_proc_make_s8vector, | |
426 | scm_i_proc_make_u16vector, scm_i_proc_make_s16vector, | |
427 | scm_i_proc_make_u32vector, scm_i_proc_make_s32vector, | |
428 | scm_i_proc_make_u64vector, scm_i_proc_make_s64vector, | |
429 | scm_i_proc_make_f32vector, scm_i_proc_make_f64vector, | |
430 | scm_i_proc_make_c32vector, scm_i_proc_make_c64vector, | |
431 | uvec_proc_vars): Removed. | |
432 | (scm_i_generalized_vector_creator): Removed. | |
433 | (scm_i_generalized_vector_type): New. | |
434 | ||
435 | * unif.h, unif.c (scm_typed_array_p, scm_make_array, | |
436 | scm_make_typed_array, scm_array_type, scm_list_to_array, | |
437 | scm_list_to_typed_array, scm_is_array, scm_is_typed_array): New. | |
438 | (scm_array_creator): Removed. | |
439 | (scm_array_p): Deprecated second PROT argument. | |
440 | (scm_dimensions_to_uniform_array, scm_list_to_uniform_array): | |
441 | Deprecated, reimplemented in terms of scm_make_typed_array and | |
442 | scm_list_to_typed_array. | |
443 | (scm_i_proc_make_vector, scm_i_proc_make_string, | |
444 | scm_i_proc_make_bitvector): Removed. | |
445 | (type_creator_table, init_type_creator_table, type_to_creator, | |
446 | make_typed_vector): New. | |
447 | (scm_i_convert_old_prototype): Removed. | |
448 | (prototype_to_type): New. | |
449 | (scm_make_uve): Deprecated, reimplemented using make_typed_vector. | |
450 | (scm_array_dimensions): Use scm_list_1 instead of scm_cons for | |
451 | minor added clarity. | |
452 | (scm_make_shared_array, scm_ra2contig): Use make_typed_vector | |
453 | instead of scm_make_uve. | |
454 | (tag_creator_table, scm_i_tag_to_creator): Removed. | |
455 | (tag_to_type): New. | |
456 | (scm_i_read_array): Use scm_list_to_typed_array instead of | |
457 | scm_list_to_uniform_array. | |
458 | ||
277e8472 MV |
459 | 2004-12-27 Marius Vollmer <mvo@zagadka.de> |
460 | ||
32b26202 MV |
461 | * unif.h, unif.c (scm_bitvector_elements): Made return value "const". |
462 | (scm_bitvector_writable_elements): New. | |
463 | (scm_bitvector_release, scm_bitvector_release_elements): | |
464 | Renamed former to latter. Added explicit call to | |
465 | scm_remember_upto_here_1. | |
466 | (scm_frame_bitvector_release, | |
467 | scm_frame_bitvector_release_elements): Renamed former to latter. | |
468 | (scm_bitvector_release_writable_elements, | |
469 | scm_bitvector_release_writable_elements): New. | |
470 | Changed all uses as required by the changes above. | |
471 | ||
472 | * srfi-4.h, srfi-4.c, srfi-4.i.c (scm_uniform_vector_elements, | |
473 | scm_u8vector_elements, etc): Made return value "const". | |
474 | (scm_uniform_vector_writable_elements, | |
475 | scm_u8vector_writable_elements, etc): New. | |
476 | (scm_uniform_vector_release, scm_uniform_vector_release_elements): | |
477 | Renamed former to latter. Added explicit call to | |
478 | scm_remember_upto_here_1. | |
479 | (scm_frame_uniform_vector_release, | |
480 | scm_frame_uniform_vector_release_elements): Renamed former to latter. | |
481 | (scm_uniform_vector_release_writable_elements, | |
482 | scm_frame_uniform_vector_release_writable_elements): New. Takes | |
483 | crown of longest identifier yet. | |
484 | Changed all uses as required by the changes above. | |
485 | ||
277e8472 MV |
486 | * vectors.h, vectors.c (scm_c_vector_set_x): Make return type |
487 | void. | |
488 | (scm_is_vector, scm_vector_p, scm_vector_length, | |
489 | scm_c_vector_length, scm_vector_ref, scm_c_vector_ref, | |
490 | scm_vector_set_x, scm_c_vector_set_x, scm_vector_to_list, | |
491 | scm_vector_move_left_x, scm_vector_move_right_x, | |
492 | scm_vector_fill_x): handle one-dimensional arrays. | |
32b26202 MV |
493 | (scm_vector_elements, scm_vector_release_elements, |
494 | scm_vector_frame_release_elements, scm_vector_writable_elements, | |
495 | scm_vector_release_writable_elements, | |
496 | scm_vector_frame_release_writable_elements): New. | |
497 | (scm_list_to_vector, scm_vector_to_list, scm_vector_fill, | |
498 | scm_vector_move_left_x, scm_vector_move_right_x): Use them. | |
277e8472 MV |
499 | |
500 | * ramap.c (scm_ramapc, scm_raeql): Use | |
501 | scm_c_generalized_vector_length instead of | |
502 | scm_uniform_vector_length. | |
503 | (scm_ramap, rafe): Use scm_c_vector_ref instead of SCM_VELTS. use | |
504 | scm_c_generalized_vector_ref instead of scm_uniform_vector_ref. | |
505 | ||
49c51610 MV |
506 | 2004-12-23 Marius Vollmer <marius.vollmer@uni-dortmund.de> |
507 | ||
508 | * continuations.h, continuations.c (scm_t_contregs): New 'offset' | |
509 | member for relocating debug frames. | |
510 | (scm_make_continuation): Set it. | |
511 | ||
512 | * stacks.c (read_frame, read_frames, scm_make_stack, | |
513 | scm_last_stack_frame, scm_stack_id): Use the new 'offset' member | |
514 | of continuations instead of calculating the offset ourselves. | |
515 | Relocate 'vect' member of scm_t_debug_frame. | |
516 | ||
3b2ee265 KR |
517 | 2004-12-16 Kevin Ryde <user42@zip.com.au> |
518 | ||
519 | * ramap.c (scm_array_map_x): Check for at least one source argument. | |
520 | ||
e120686a KR |
521 | 2004-12-14 Kevin Ryde <user42@zip.com.au> |
522 | ||
523 | * srfi-13.c (string-any, string-every): Use a scheme wrapper around | |
524 | the C code so for the final call to the predicate procedure is a tail | |
525 | call, per SRFI-13 spec. | |
526 | ||
680b5237 KR |
527 | 2004-12-10 Kevin Ryde <user42@zip.com.au> |
528 | ||
529 | * eq.c (scm_eq_p, scm_eqv_p, scm_equal_p): Update docstrings from | |
530 | recent revision to the reference manual. | |
531 | ||
532 | * numbers.c (scm_modulo): Amend fixme comment about negative divisor | |
533 | with "%", C99 says it's well-defined. | |
534 | ||
535 | * socket.c (scm_from_ipv6): Just use mpz_import. Don't bother trying | |
536 | to fit scm_from_ulong_long, since that uses mpz_import anyway. Don't | |
537 | bother trying to fit scm_from_ulong, not really worth the trouble if | |
538 | addresses are more than 4 bytes usually. | |
539 | ||
446d320c KR |
540 | 2004-11-30 Kevin Ryde <user42@zip.com.au> |
541 | ||
542 | * gc_os_dep.c (NetBSD): Test __m68k__ and __arm__ as well as m68k and | |
543 | arm32. Reported by Greg Troxel. | |
544 | ||
f2654760 MV |
545 | 2004-11-14 mvo <mvo@zagadka.de> |
546 | ||
547 | * unif.c, unif.h (scm_i_cvref): Made non-static for ramap.c. | |
548 | ||
549 | * Makefile.am (INCLUDES): It is "@LTDLINCL@", not "@LTDLINC@". | |
550 | ||
d550e35f MV |
551 | 2004-11-12 Marius Vollmer <marius.vollmer@uni-dortmund.de> |
552 | ||
553 | Enclosed arrays are now their own smob. This has been done to | |
554 | make the code more explicit about them and to prepare for the time | |
f2654760 MV |
555 | when generalized vectors include arbitrary one-dimensional |
556 | arrays. (Uptonow, enclosed arrays have been recognized by their | |
557 | use of an array as their storage 'vector'. When all generalized | |
558 | vectors are allowed as storage, including one-dimensional arrays, | |
559 | this will no longer work.) | |
d550e35f MV |
560 | |
561 | * unif.h, unif.c: (scm_tc16_enclosed_array, SCM_ENCLOSED_ARRAYP): | |
562 | New. | |
563 | (exactly_one_third, singp): Removed. | |
564 | (scm_array_p, scm_array_dimensions, scm_shared_array_root, | |
565 | scm_shared_array_offset, scm_shared_array_increments): Handle | |
566 | enclosed arrays explicitely. | |
567 | (scm_array_rank): Likewise. Also, do not return zero for | |
568 | non-arrays, signal an error instead since arrays with rank zero do | |
569 | exist. | |
570 | (scm_i_make_ra): New, for specifying the tag of the new array. | |
571 | (scm_make_enclosed_array): Use it. | |
572 | (scm_make_ra): Reimplemented in terms of scm_i_make_ra. | |
573 | (scm_make_shared_array): Use scm_c_generalized_vector_length | |
574 | instead of scm_uniform_vector_length. | |
575 | (scm_array_in_bounds_p): Rewritten to be much cleaner. | |
576 | (scm_i_cvref): New, doing the job of scm_cvref. | |
577 | (scm_cvref): Use scm_i_cvref. | |
578 | (scm_array_ref): Do not accept non-arrays when no indices are | |
579 | given. Use scm_i_cvref to do the actual access. | |
580 | ("uniform-array-set1"): Do not register. | |
581 | (scm_array_set_x, scm_uniform_array_read_x, | |
582 | scm_uniform_array_write): Handle enclosed arrays explicitly. | |
583 | (ra2l): Use scm_i_cvref instead of scm_uniform_vector_ref to also | |
584 | handle enclosed arrays. | |
585 | (scm_array_to_list): Handle enclosed arrays explicitly. | |
586 | (rapr1): Removed. | |
587 | (scm_i_print_array_dimension): Use scm_i_cvref to also handle | |
588 | enclosed arrays. | |
589 | (scm_i_print_enclosed_array): New. | |
590 | (tag_proto_table, tag_creator_table): Renamed former to latter. | |
591 | Added "a" and "b" for strings and bitvectors, resp. | |
592 | (scm_i_tag_to_prototype, scm_i_tag_to_creator): Renamed former to | |
593 | latter. Tag "a" is in the table now, no need to handle it as a | |
594 | legacy tag. | |
595 | (scm_raprin1): Just call scm_iprin1. | |
596 | (scm_array_creator, scm_array_prototype): Handle enclosed arrays | |
597 | explicitly. | |
598 | (scm_init_unif): Initialize scm_tc16_enclosed_array smob. | |
599 | Use scm_i_print_array as printer for scm_tc16_array. | |
600 | ||
2ed34885 MV |
601 | 2004-11-10 Marius Vollmer <mvo@zagadka.de> |
602 | ||
823086c1 MV |
603 | * ramap.c (cind): Changed second arg to be pointer to long instead |
604 | of uniform vector. | |
605 | (scm_ramapc): Allocate index vector with scm_malloc and not as | |
d550e35f | 606 | uniform vector. Wrap it in a frame so that it gets properly freed. |
823086c1 MV |
607 | (scm_array_index_map_x): Likewise. |
608 | ||
609 | * unif.c: Changed all uses of scm_array_prototype to | |
610 | scm_array_creator. (scm_i_get_old_prototype): Signal error when no | |
611 | prototype is known. | |
612 | (scm_uniform_array_read_x, scm_uniform_array_write): Reimplemented | |
613 | in terms of scm_uniform_vector_read_x and | |
614 | scm_uniform_vector_write, respectively. Strings and | |
615 | bitvector support has been dropped. | |
616 | ||
2ed34885 MV |
617 | * srfi-4.h, srfi-4.c: Do not include <libguile.h>, include the |
618 | needed files directly. Include config.h, <unistd.h> and <io.h> | |
619 | when available. | |
620 | (scm_uniform_vector_read_x, scm_uniform_vector_write): New. | |
621 | ||
2c72f253 MV |
622 | 2004-11-09 Marius Vollmer <mvo@zagadka.de> |
623 | ||
624 | * gh_data.c (gh_uniform_vector_length): Properly use | |
625 | scm_c_uniform_vector_length instead of scm_uniform_vector_length. | |
626 | ||
3cc0a296 MV |
627 | 2004-11-09 Marius Vollmer <marius.vollmer@uni-dortmund.de> |
628 | ||
629 | * srfi-4.h (scm_c_uniform_vector_ref, scm_c_uniform_vector_set_x): | |
630 | New. | |
631 | (scm_i_uniform_vector_creator): Removed. | |
632 | (scm_i_generalized_vector_creator): New. | |
633 | (scm_uniform_vector_length, scm_uniform_element_size): Do not | |
634 | handle generalized vectors, only uniform numeric vectors. | |
635 | (alloc_uvec): Do length check here... | |
636 | (make_uvec): ...but not here. | |
637 | (coerce_to_uvec): Use new generalized vector functions to handle | |
638 | all kinds of vectors in one go. | |
639 | ||
640 | * tags.h (scm_tc7_bvect): Renamed to scm_tc7_unused7, renaming the | |
641 | remaining scm_tc7_unused tags to get a neatly ordered list. | |
642 | ||
643 | * eq.c, evalext.c, gc-card.c, gc-mark.c, objects.c, print.c: Do no | |
644 | longer handle scm_tc7_bvect bitvectors. | |
645 | ||
646 | * ramap.c: Use the new generalized vector functions to handle all | |
647 | vector like things. | |
648 | ||
649 | * vectors.h, vectors.c (scm_is_vector, scm_c_vector_length, | |
650 | scm_c_vector_ref, scm_c_vector_set_x, scm_generalized_vector_p, | |
651 | scm_generalized_vector_length, scm_generalized_vector_ref, | |
652 | scm_generalized_vector_set_x, scm_generalized_vector_to_list, | |
653 | scm_is_generalized_vector, scm_c_generalized_vector_length, | |
654 | scm_c_generalized_vector_ref, scm_c_generalized_vector_set_x): | |
655 | New. | |
656 | ||
657 | * unif.h, unif.c (scm_bitvector_p, scm_bitvector, | |
658 | scm_make_bitvector, scm_bitvector_length, scm_bitvector_ref, | |
659 | scm_bitvector_set_x, scm_list_to_bitvector, scm_bitvector_to_list, | |
660 | scm_bitvector_fill_x, scm_is_bitvector, scm_c_make_bitvector, | |
661 | scm_c_bitvector_length, scm_c_bitvector_ref, | |
662 | scm_c_bitvector_set_x, scm_bitvector_elements, | |
663 | scm_bitvector_release, scm_frame_bitvector_release, | |
664 | scm_tc16_bitvector, bitvector_free, bitvector_print, | |
665 | bitvector_equalp, count_ones, find_first_one): New. | |
666 | (scm_bit_count, scm_bit_position, scm_bit_set_star_x, | |
667 | scm_bit_count_star, scm_bit_invert_x, scm_istr2bve): Rewritten | |
668 | using the new C API for bitvectors and maybe count_ones or | |
669 | find_first_one, as appropriate. | |
670 | (SCM_I_MAX_LENGTH, SCM_BITVECTOR_P, SCM_BITVECTOR_BASE, | |
671 | SCM_SET_BITVECTOR_BASE, SCM_BITVECTOR_MAX_LENGTH, | |
672 | SCM_BITVECTOR_LENGTH, SCM_MAKE_BITVECTOR_TAG, | |
673 | SCM_SET_BITVECTOR_LENGTH): Removed. Replaced all uses with the | |
674 | new functions from above. | |
675 | (scm_i_proc_make_vector, scm_i_proc_make_string, | |
676 | scm_i_proc_make_bitvector): Made non-static for use in | |
677 | scm_i_generalized_vector_creator. | |
678 | (scm_make_u1vector): Removed, replaced by scm_make_bitvector. | |
679 | (scm_make_uve): Validate that the created object is a generalized | |
680 | vector. | |
681 | (scm_i_legacy_tag): Removed. | |
682 | (scm_i_print_array): Do it here. | |
683 | (scm_raprin1): Only print enclosed arrays. | |
684 | ||
685 | * Makefile.am (DOT_DOC_FILES): Added srfi-4.doc. | |
686 | ||
c24d026b MV |
687 | 2004-11-04 Marius Vollmer <marius.vollmer@uni-dortmund.de> |
688 | ||
1f2328fe MV |
689 | * srfi-4.c (make_uvec): Use SCM_I_SIZE_MAX instead of SIZE_MAX for |
690 | added portability. | |
691 | ||
692 | * chars.c (scm_charnames, scm_charnums): Added "sp" as an alias | |
693 | for "space". Thanks to Bruce Korb! | |
694 | ||
c24d026b MV |
695 | * rw.c (scm_read_string_x_partial): Bugfix, apply offset to dest |
696 | only after dest has been set. Thanks to Hyper Division! | |
697 | ||
698 | * gh_data.c (gh_uniform_vector_length): Use | |
699 | scm_uniform_vector_length instead of SCM_UVECTOR_LENGTH. | |
700 | ||
d4ea47c8 MV |
701 | 2004-11-03 Marius Vollmer <mvo@zagadka.de> |
702 | ||
703 | * unif.h (SCM_UVECTOR_BASE, SCM_SET_UVECTOR_BASE, | |
704 | SCM_UVECTOR_MAXLENGTH, SCM_UVECTOR_LENGTH, SCM_MAKE_UVECTOR_TAG, | |
705 | SCM_SET_UVECTOR_LENGTH): Removed. | |
706 | ||
236288e2 MV |
707 | 2004-11-02 Marius Vollmer <mvo@zagadka.de> |
708 | ||
709 | Content-type: text/html