*** empty log message ***
[bpt/guile.git] / libguile / ChangeLog
CommitLineData
5c790b44
RB
12001-11-18 Rob Browning <rlb@defaultvalue.org>
2
3 * version.c
4 (s_scm_major_version): use SCM_MAJOR_VERSION.
5 (s_scm_minor_version): use SCM_MINOR_VERSION.
6 (s_scm_micro_version): use SCM_MICRO_VERSION.
7 (s_scm_version): use SCM_MAJOR_VERSION, SCM_MINOR_VERSION, and
8 SCM_MICRO_VERSION.
9
10 * version.h.in
11 (SCM_MAJOR_VERSION): renamed from SCM_GUILE_MAJOR_VERSION.
12 (SCM_MINOR_VERSION): renamed from SCM_GUILE_MINOR_VERSION.
13 (SCM_MICRO_VERSION): renamed from SCM_GUILE_MICRO_VERSION.
14
694a9bb3
NJ
152001-11-18 Neil Jerram <neil@ossau.uklinux.net>
16
17 * vectors.c (scm_vector_move_left_x, scm_vector_move_right_x):
18 Rewrite docstrings without reference to substring-move-left/right,
19 since the latter no longer exist.
20
302c12b4
DH
212001-11-17 Dirk Herrmann <D.Herrmann@tu-bs.de>
22
23 * eval.c: Removed bogus comment about acros.
24
25 (scm_unmemocar): Use !SCM_CONSP instead of SCM_IMP.
26 Minimize scope of local variable. Eliminate dependency on
27 macro DEBUG_EXTENSIONS.
28
29 (s_splicing): New error message string.
30
31 (scm_m_body): Issue 'bad body' message rather than 'missing
32 expression' message.
33
34 (scm_m_quote): Eliminate unnecessary copying.
35
36 (scm_m_lambda, scm_m_letstar, scm_m_letrec, scm_m_let): Leave the
37 checking of the body to scm_m_body.
38
39 (scm_m_do): Move comment to function header. Rename arg1 to
40 binding. Made the code a bit easier to read.
41
42 (evalcar): Removed.
43
44 (iqq): Added a comment. Changed the depth parameter to
45 unsigned. Use size_t for vector lengths. Make sure vector object
46 is gc protected as long as its contents are read. Add some syntax
47 checks. Get rid of unnecessary SCM_IMP test. Clean up the
48 control structure a bit.
49
50 (scm_m_delay): Added comment about the implementation of
51 scm_m_delay.
52
53 (scm_m_define): Add comment about guile's currying define
54 syntax. Renamed 'proc' to 'name'. Eliminate dependency on macro
55 DEBUG_EXTENSIONS. Simplified code a bit. Eliminate SICP code.
56
57 (scm_m_letrec1): Removed. Part of the functionality is taken
58 over by the new function 'transform_bindings'.
59
60 (transform_bindings): New function. Takes over some of the
61 functionality of removed function 'scm_m_letrec1', namely to split
62 a list of bindings into a reversed list of variables and a list of
63 initializers.
64
65 (scm_m_letrec): Call 'transform_bindings'.
66
67 (scm_m_let): Minimized scope of local variables. Renamed 'proc'
68 to 'temp' and 'arg1' to 'binding'. Eliminated redundant SCM_NIMP
69 test. Use 'transform_bindings'. Fixed scoping error with named
70 let (Thanks to Aubrey Jaffer for reporting the bug and to Neil
71 Jerram for suggesting the fix). Cleaned up the control structure
72 a bit.
73
74 (scm_m_expand_body): Use 'transform_bindings'. Eliminated
75 unnecessary consing. Eliminated unnecessary
76 SCM_DEFER/ALLOW_INTS.
77
78 (SCM_CEVAL): Un-obfuscated some loops.
79
cecb4a5e
NJ
802001-11-16 Neil Jerram <neil@ossau.uklinux.net>
81
8f85c0c6
NJ
82 * gc.h (scm_unhash_name): Old declaration removed.
83
84 * eval.c (s_scm_eval): Change @var{primitive-eval} to
85 @code{primitive-eval}.
86
87 * feature.c, vectors.c, net_db.c, unif.c, weaks.c, struct.c,
88 version.c, alist.c, ports.c, ramap.c, unif.c, strings.c, list.c:
89 Change @deffnx lines in docstrings to say {Scheme Procedure}
90 rather than primitive or procedure.
91
92 * posix.c (scm_execl), filesys.c (scm_close), unif.c
93 (scm_array_set_x, scm_array_contents, scm_uniform_array_read_x,
94 scm_bit_set_star_x, scm_bit_invert_x), ramap.c (scm_array_fill_x,
95 scm_array_for_each, scm_array_index_map_x), vectors.c (scm_vector,
96 scm_make_vector, scm_vector_to_list, scm_vector_fill_x), strop.c
97 (scm_string_split, scm_string_ci_to_symbol), strings.c
98 (scm_string_p), sort.c (scm_merge), print.c (scm_newline),
99 macros.c (scm_macro_type), alist.c (scm_acons, scm_assq):
100 Docstring fixes and improvements reflecting edits that have been
101 made in the reference manual source.
102
103 * objprop.c (scm_object_properties, scm_set_object_properties_x,
104 scm_object_property, scm_set_object_property_x): Remove invalid
105 @deffnx lines for corresponding procedure property primitives.
106
cecb4a5e
NJ
107 These changes add a @deffnx C function declaration and function
108 index entries for each Guile primitive to the copy of the doc
109 snarf output that is used for reference manual synchronization.
110 Online help is unchanged.
111
112 * snarf.h (SCM_SNARF_DOCS): Output primitive's C function name.
113 (SCM_DEFINE, SCM_DEFINE1, SCM_REGISTER_PROC): Supply to C function
114 name to SCM_SNARF_DOCS.
115
116 * guile-snarf-docs-texi.in: Pass the shell script's arguments into
117 snarf-check-and-output-texi.
118
119 * Makefile.am (guile-procedures.texi): New rule.
120 (BUILT_SOURCES, guile.texi, guile-procedures.txt, CLEANFILES):
121 Changed so that the last stage of doc snarfing is now performed
122 twice, once to produce guile-procedures.txt for online help, and
123 once to produce guile.texi for reference manual synchronization.
124
ddea3325
DH
1252001-11-15 Dirk Herrmann <D.Herrmann@tu-bs.de>
126
127 * eval.c (RETURN): Wrap in do{}while(0) in order to make it
128 safely usable as a single statement followed by a ';', for example
129 in an if statement.
130
131 (SCM_CEVAL, SCM_APPLY): Clean up code using 'RETURN'.
132
72dd0a03
NJ
1332001-11-13 Neil Jerram <neil@ossau.uklinux.net>
134
135 * random.c (scm_random_solid_sphere_x,
136 scm_random_hollow_sphere_x): Correct "shere" typos.
137
138 * hashtab.c (scm_hash_fold): Add missing apostrophe to docstring.
139
140 * version.c (scm_version): Update docstring to include
141 `micro-version'.
142
6558eda6
MV
1432001-11-13 Marius Vollmer <mvo@zagadka.ping.de>
144
409b8588
MV
145 * modules.c (scm_c_export): Call va_end after collecting the
146 symbols.
147
adb8c0f2
MV
148 * strop.h, strop.c (scm_substring_move_left_x,
149 scm_substring_move_right_x): Removed.
150
6558eda6
MV
151 * __scm.h (HAVE_UINTPTR_T, HAVE_PTRDIFF_T, HAVE_LONG_LONG,
152 HAVE_LONG_LONGS): Define to "1" when defining them, to mirror what
153 configure does.
154
5d8fc640
MV
1552001-11-12 Marius Vollmer <mvo@zagadka.ping.de>
156
157 * numbers.c: Document macros to define when including
158 num2integral.i.c. MAX_VALUE and MIN_VALU are no longer used, we
159 now rely on SIZEOF_ macros that have been figured out at
160 configure time.
161
162 * num2integral.i.c: Adapt to new interface.
163 (NUM2INTEGRAL): Test whether a fixnum can be represented in the
164 target type by casting it and checking whether it is still the
165 same. Do not try to handle bignums for integral types that are
166 smaller than fixnums. When handling bignums, collect the
167 magnituse first into a unsigned type, and correctly check for
168 overflow.
169 (INTEGRAL2BIG): Do not use MIN_VALUE explicitely by observing that
170 only -MIN_VALUE can still be negative of all negative numbers (in
171 twos-complement).
172
173 * tags.h (SIZEOF_SCM_T_BITS): Define it appropriately.
174
175 * __scm.h: Define HAVE_UINTPTR_T, HAVE_PTRDIFF_T and
176 HAVE_LONG_LONG depending on whether their size is non-zero.
177
d6b8cf11
TTN
1782001-11-11 Thien-Thi Nguyen <ttn@glug.org>
179
180 * strop.c (scm_string_null_p): Docfix; nfc.
181 Thanks to Scott Lenser.
182
9401323e
NJ
1832001-11-07 Neil Jerram <neil@ossau.uklinux.net>
184
185 * extensions.c (scm_load_extension): Canonicalize docstring
186 whitespace.
187
188 * unif.c (scm_uniform_array_write), ports.c
189 (scm_current_output_port, scm_force_output), dynwind.c
190 (scm_dynamic_wind), scmsigs.c (scm_setitimer, scm_getitimer),
191 filesys.c (scm_open, scm_lstat), struct.c
192 (scm_make_struct_layout), random.c (scm_random,
193 scm_random_solid_sphere_x, scm_random_hollow_sphere_x, strop.c
194 (scm_i_index): Remove superfluous whitespace from end of docstring
195 lines.
196
197 * filesys.c (scm_select), guardians.c (scm_guardian_greedy_p),
198 strings.c (scm_make_string), variable.c (scm_make_variable,
199 scm_make_undefined_variable, scm_variable_p, scm_variable_set_x,
200 scm_variable_bound_p), scmsigs.c (scm_setitimer, scm_getitimer),
201 posix.c (scm_crypt), struct.c (scm_make_vtable_vtable), hashtab.c
202 (scm_hash_fold), ports.c (scm_port_for_each): Remove superfluous
203 newline at end of docstrings.
204
205 * modules.c (scm_set_current_module): Add missing newline to
206 docstring.
207
b4e15479
SJ
2082001-11-07 Stefan Jahn <stefan@lkcc.org>
209
210 * win32-socket.[ch]: New files. Defines Winsock-API error codes
211 and makes them available through Guile. That is because the
212 Winsock-API does not store its errors in `errno' and thus cannot
213 return error messages via `strerror (errno)'.
214
215 * socket.c (scm_init_socket): Initialize `win32-socket' part
216 here under M$-Windows.
217
d6b8cf11 218 * numbers.h: Added missing declaration of
b4e15479
SJ
219 `scm_sys_check_number_conversions()'.
220
221 * error.c: Local definition of SCM_I_STRERROR and SCM_I_ERRNO
222 and use in `(strerror)' and `(system-error)'.
223
d6b8cf11 224 * Makefile.am (EXTRA_libguile_la_SOURCES): Added
b4e15479
SJ
225 `win32-socket.[ch]' to extra source and header files.
226
7ab89df1
MV
2272001-11-06 Marius Vollmer <mvo@zagadka.ping.de>
228
229 * script.c (scm_shell_usage, scm_compile_shell_switches): Prepend
230 a call to turn-on-debugging when --debug has been given instead of
231 turning it on directly. Also, handle new `--no-debug' option,
232 which might suppress the call to turn-on-debugging.
233
0233bfc1
SJ
2342001-11-05 Stefan Jahn <stefan@lkcc.org>
235
236 * struct.c (s_scm_struct_vtable_p): Corrected docstring.
237
8f99e3f3
SJ
2382001-11-04 Stefan Jahn <stefan@lkcc.org>
239
240 * Makefile.am (libguile_la_LIBADD): Added $(THREAD_LIBS_LOCAL)
d6b8cf11 241 here (was at guile_LDADD) which describes the dependency
8f99e3f3
SJ
242 correctly and allows a clean build on Win32.
243
d6b8cf11 244 * __scm.h (SCM_API): Follow-up patch. Renamed __FOO__ macros
8f99e3f3
SJ
245 into FOO.
246
247 * __scm.h: USE_DLL_IMPORT indicates the usage of the DLL
248 import macros for external libraries (libcrypt, libqthreads,
249 libreadline and libregex).
250
251 * coop-defs.h: Include <winsock2.h> for `struct timeval'.
252
253 * posix.c (flock): Added support for flock() in M$-Windows.
254
255 * guile.c (SCM_IMPORT): Follow-up patch. Use SCM_IMPORT instead
256 of __SCM_IMPORT__.
257
258 * fports.c (getflags): Differentiate reading and writing pipes
259 descriptors.
260
261 * filesys.c (S_IS*): Redefine all of the S_IS*() macros for
262 M$-Windows.
263
264 * coop.c (coop_condition_variable_timed_wait_mutex): Use
265 conditionalized error code if `ETIMEDOUT' is not available.
266 (scm_thread_usleep): Remove bogus declaration of `struct timeval
267 timeout'.
268
269 * numbers.c (PTRDIFF_MIN): Moved this definition where it actually
270 belongs. That is because NO_PREPRO_MAGIC gets undefined after
271 each inclusion of `num2integral.i.c'.
272 (SIZE_MAX): Define NO_PREPRO_MAGIC if SIZE_MAX is undefined.
273
4e21fa60
MV
2742001-11-03 Marius Vollmer <mvo@zagadka.ping.de>
275
276 * eval.c (scm_m_begin): Allow `(begin)`, with no subforms.
277 (SCM_CEVAL): Evaluate an empty `begin' to SCM_UNSPECIFIED.
278
08112c95
MD
2792001-11-02 Mikael Djurfeldt <mdj@linnaeus>
280
7663c008
MD
281 * print.c (scm_iprin1): Mark print state as revealed when
282 dispatching to generic write or display.
283
08112c95
MD
284 * unif.c (scm_ra2contig): Fixed memory overwrite bug.
285
f712d833
MV
2862001-11-02 Marius Vollmer <mvo@zagadka.ping.de>
287
288 Support for native Win32. Thanks to Stefan Jahn!
d6b8cf11 289
f712d833
MV
290 * Makefile.am: Add win32-uname.c, win32-uname.h, win32-dirent.c
291 and win32-dirent.h to extra source and header files. These
292 include the uname() and the POSIX dirent interface implementation
293 for M$-Windows. Put `-no-undefined' into LDFLAGS to support
294 linkers which do not allow unresolved symbols inside shared
295 libraries. Corrected `guile_filter_doc_snarfage$(EXEEXT)'
296 dependency.
297
d6b8cf11
TTN
298 * __scm.h: Defined SCM_API. This macro gets prepended to all
299 function and data definitions which should be exported or imported
f712d833
MV
300 in the resulting dynamic link library in the Win32 port.
301
302 * __scm.h, alist.h, arbiters.h, async.h, backtrace.h, boolean.h,
d6b8cf11 303 chars.h, continuations.h, coop-defs.h, coop-threads.h,
f712d833
MV
304 debug-malloc.h, debug.h, deprecation.h, dynl.h, dynwind.h,
305 environments.h, eq.h, error.h, eval.h, evalext.h, extensions.h,
306 feature.h, filesys.h, fluids.h, fports.h, gc.h, gdb_interface.h,
307 gdbint.h, gh.h, goops.h, gsubr.h, guardians.h, hash.h, hashtab.h,
308 hooks.h, init.h, ioext.h, iselect.h, keywords.h, lang.h, list.h,
d6b8cf11 309 load.h, macros.h, mallocs.h, modules.h, net_db.h, numbers.h,
f712d833
MV
310 objects.h, objprop.h, options.h, pairs.h, ports.h, posix.h, print.h,
311 procprop.h, procs.h, properties.h, ramap.h, random.h, rdelim.h,
312 read.h, regex-posix.h, root.h, rw.h, scmsigs.h, script.h, simpos.h,
313 smob.h, socket.h, sort.h, srcprop.h, stackchk.h, stacks.h, stime.h,
314 strings.h, strop.h, strorder.h, strports.h, struct.h, symbols.h,
315 tags.h, threads.h, throw.h, unif.h, values.h, variable.h, vectors.h,
316 vports.h, weaks.h:
317 Prefixed each each exported symbol with SCM_API.
318
d6b8cf11 319 * continuations.c: Added comment about the use of the extern
f712d833
MV
320 declarations of {get,set}context() functions used in the ia64 port.
321
322 * continuations.h, gc.c: `__libc_ia64_register_backing_store_base'
323 is meant to be a `unsigned long *'.
324
325 * filesys.c: Include `direct.h' if possible. Use local
326 `win32-dirent.h' for the native M$-Windows port. Define S_IS*()
327 macros for M$-Windows. Implementation of `fstat_Win32()' which is
328 able to differentiate between sockets and other file descriptors.
329 Use this function as wrapper in `scm_fstat()'. Fixed typo in
330 `scm_dirname()'.
331
332 * fports.c: Include `io.h' is possible. Put `*fp' into referring
333 statement block in `scm_fport_buffer_add()'.
334 Some corrections in `getflags()'.
d6b8cf11 335
f712d833
MV
336 * gdb_interface.h (GDB_INTERFACE): Also support __CYGWIN__.
337
338 * guile.c: Make sure to define __SCM_IMPORT__ for shared library
339 build on Win32. Disable preloaded symbols on Win2 platforms.
340
341 * ioext.c, ports.c: Include `io.h' is possible.
342
343 * mkstemp.c: Include `process.h' is possible.
344
345 * net_db.c: Disable extern declaration of `h_errno' for __CYGWIN__,
346 too.
347 Put `scm_return_entry()' into HAVE_GETSERVENT conditional.
348
349 * posix.c: Remove unnecessary dirent includes and defines. Include
350 local `win32-uname.h' for MinGW. Extern declaration of
351 `mkstemp()' for systems where it does not exists. Make
352 `getlogin()' available on M$-Windows.
353
354 * scmsigs.c: Made `usleep()' avalable on MinGW.
355
356 * stime.c: On M$-Windows `tzname[]' is known to be `_tzname[]'.
357
358 * win32-dirent.c: Include "win32-dirent.h", not "dirent.h".
359
360 * win32-uname.c: Include "win32-uname.h", not "uname.h".
361
d245ce23
MD
3622001-10-28 Mikael Djurfeldt <mdj@linnaeus>
363
364 * unif.c (scm_uniform_array_read_x, scm_uniform_array_write):
365 Don't apply scm_uniform_vector_length on arrays.
366
8ea46249
DH
3672001-10-14 Dirk Herrmann <D.Herrmann@tu-bs.de>
368
369 * eval.c (scm_lookupcar, scm_m_letstar, scm_m_do, iqq,
370 scm_m_define, scm_m_letrec1, scm_m_let, scm_m_expand_body,
371 scm_macroexp, unmemocopy, scm_eval_args, scm_deval_args,
372 SCM_CEVAL, scm_map, scm_init_eval): When building lists, prefer
373 scm_list_<n> over scm_cons[2]?.
374
375 (scm_unmemocar, scm_m_cond, scm_m_letstar, scm_m_letrec1,
376 scm_m_let, scm_m_atbind, unmemocopy, SCM_CEVAL, SCM_APPLY): Use
377 SCM_C[AD][AD]R instead of explicit form.
378
379 (scm_m_set_x, scm_m_cond, scm_m_letstar, scm_m_do): Reordered
380 comparison parameters.
381
382 (scm_m_case, scm_m_cond, scm_m_letstar, scm_m_do, SCM_CEVAL): Use
383 !SCM_NULLP instead of SCM_NIMP.
384
385 (scm_m_case): Don't copy the form. Renamed proc to clause and
386 minimized its scope. Renamed x to clauses. Removed side
387 effecting operation from macro call.
388
389 (scm_m_cond): Don't copy the form. Renamed arg1 to clause and
390 minimized its scope. Renamed x to clauses. Minimized the scope
391 of variable 'len'. Make sure the else clause is treated specially
392 even in case of '=>' occurences. Don't change the else to #t in
393 order to be able to distinguish this case in the evaluator. Leave
394 type checking of the recipient to the evaluator.
395
396 (scm_c_improper_memq): Made the comment somewhat clearer.
397
398 (scm_m_lambda): Renamed proc to formals. Removed unnecessary
399 test for SCM_IM_LET at the place of the formal parameters.
400 Simplified the formal parameter checking.
401
402 (scm_m_letstar): Added Comment. Renamed proc to bindings.
403 Renamed arg1 to binding and minimized its scope. Eliminated
404 unnecessary consing.
405
406 (scm_m_do): Renamed proc to bindings. Minimized the scope of
407 variable 'len'.
408
409 (build_binding_list): New static function.
410
411 (unmemocopy): Don't use SCM_TYP7 on pairs (it's unclean).
412 Further, split up the 'letrec' unmemoizing code to the
413 corresponding parts for 'do', 'let' and 'letrec', adding comments
414 to each form. Cleanup the handling of the do form (This removes
415 some *real* code :-).
416
417 (SCM_CEVAL): Removed side effecting operation from macro call.
418 Handle the 'else clause of the 'cond form specially - the symbol
419 'else is not replaced with #t any more.
420
8186c4f5
GH
4212001-10-14 Gary Houston <ghouston@arglist.com>
422
423 * version.c (scm_version): use sprintf instead of snprintf,
424 for portability. thanks to Bill Schottstaedt.
425
89759084
MD
4262001-10-14 Mikael Djurfeldt <mdj@linnaeus>
427
428 * read.c (scm_lreadr): When user-defined hash procedure returns
429 SCM_UNSPECIFIED: Fall back to standard handling instead of raising
430 an exception. (This prevents parsing of uniform vectors from
431 interfering with parsing of numbers.)
432
9c7ce563
MV
4332001-10-13 Marius Vollmer <mvo@zagadka.ping.de>
434
435 * numbers.c: Set NO_PREPRO_MAGIC when defining our version of
436 PTRDIFF_MIN. Thanks to Ken Raeburn.
437
4382001-10-07 Marius Vollmer <mvo@zagadka.ping.de>
439
440 * Makefile.am (EXTRA_libguile_la_SOURCES): Added "mkstemp.c".
441
442 * eval.c (scm_m_atbind): First try to find the variable without
443 defining it locally; when it has not been found, define it
444 locally.
445
446 * modules.c (module_variable): Pass over variables that exist but
447 are unbound.
448
4492001-10-06 Marius Vollmer <mvo@zagadka.ping.de>
450
451 * backtrace.c (display_backtrace_file_and_line): Only use
452 scm_basename when POSIX support is compiled in. Thanks to Chris
453 Cramer.
454
1fe5e088
DH
4552001-10-13 Dirk Herrmann <D.Herrmann@tu-bs.de>
456
457 * numbers.c (mem2uinteger): Return number read so far when coming
458 across a hexdigit after having read a # or if not reading a hex
459 value. This will enable the calling code to correctly handle
460 forms like 1e2. (The background is, that the exponent markers d,
461 e and f are also hexdigits.) Thanks to Mikael Djurfeldt for
462 providing this patch.
463
464 (mem2complex): Fix erroneous double-negation. Now, numbers like
465 1-i will be read correctly.
466
68665a97
MD
4672001-10-12 Mikael Djurfeldt <mdj@linnaeus>
468
469 * debug.c (scm_mem_to_proc): Fixed typo in previous change.
470
471 * validate.h (SCM_VALIDATE_DOUBLE_DEF_COPY): New macro.
472
d5cf5324
DH
4732001-10-12 Dirk Herrmann <D.Herrmann@tu-bs.de>
474
475 * print.c (scm_print_state_vtable, print_state_pool):
476 Initialize. These variables are now registered as gc roots.
477
478 (scm_current_pstate): Update documentation.
479
480 (scm_current_pstate, scm_make_print_state, scm_free_print_state,
481 scm_prin1, scm_init_print): print_state_pool is registered as a
482 gc root and thus does not need to be protected by a surrounding
483 pair any more.
484
485 (make_print_state): The car of print_state_pool no longer holds
486 the scm_print_state_vtable.
487
488 (scm_current_pstate, scm_make_print_state, print_circref,
489 scm_iprin1, scm_prin1, scm_iprlist): Prefer !SCM_<foo> over
490 SCM_N<foo>.
491
492 (scm_prin1): When building lists, prefer scm_list_<n> over
493 scm_cons[2]?.
494
495 (scm_iprlist): Removed a redundant SCM_IMP test.
496
497 (scm_simple_format): Use SCM_EQ_P to compare SCM values.
498
37c56aec
DH
4992001-10-11 Dirk Herrmann <D.Herrmann@tu-bs.de>
500
501 * debug.c (scm_make_iloc): Prefer !SCM_<foo> over SCM_N<foo>.
502
503 (scm_memcons, scm_mem_to_proc): When building lists, prefer
504 scm_list_<n> over scm_cons[2]?.
505
506 (scm_mem_to_proc): Prefer SCM_CONSP over SCM_NIMP.
507
508 (scm_procedure_name): Use SCM_CADR instead of explicit form.
509
510 (debugobj_print): Coerce scm_intprint arg 1 to long, not int.
511 Thanks to Rob Browning for the patch (see log entry 2001-09-21) -
512 for some reason his patch didn't make it into the cvs.
513
79d34f68
DH
5142001-10-09 Dirk Herrmann <D.Herrmann@tu-bs.de>
515
516 * numbers.c (mem2decimal_from_point): Cleaned up the parsing a
517 little bit - should even be somewhat more accurate now.
518
5e137c65
RB
5192001-10-08 Rob Browning <rlb@defaultvalue.org>
520
521 * gc.c: support ia64 register backing store.
522 (SCM_MARK_BACKING_STORE): new macro.
523
524 * continuations.h: support ia64 register backing store.
525 (struct scm_t_contregs): add ia64 register backing store.
526
527 * continuations.c: support ia64 register backing store.
528 (continuation_mark): mark ia64 register backing store.
529 (continuation_free): free ia64 register backing store.
530 (scm_make_continuation): capture ia64 register backing store.
531 (copy_stack_and_call): copy ia64 register backing store.
532
ee083ac2
DH
5332001-10-08 Dirk Herrmann <D.Herrmann@tu-bs.de>
534
535 * hashtab.c (scm_hash_fn_create_handle_x): The result of assoc_fn
536 is known to be #f if no entry is found. Thus, use !SCM_FALSEP
537 instead of SCM_NIMP to test for that case.
538
539 * strings.h (SCM_SET_STRING_LENGTH): Cast the length to
540 scm_t_bits instead of long.
541
71dcdbf9
MV
5422001-10-06 Marius Vollmer <mvo@zagadka.ping.de>
543
544 * tags.h (SCM_T_BITS_MAX, SCM_T_SIGNED_BITS_MAX,
545 SCM_T_SIGNED_BITS_MIN): New.
546 * numbers.h (SCM_MOST_POSITIVE_FIXNUM, SCM_MOST_NEGATIVE_FIXNUM):
547 Use them to make these macros computable by the preprocessor.
548
549 * num2integral.i.c (INTEGRAL2NUM): Let the preprocessor test
550 whether the integral type fits in a fixnum, not the compiler.
551 This removes a spurious compiler warning. Also, honor the
552 NO_PREPRO_MAGIC flag to suppress any preprocessor tests. This is
553 needed for `long long's.
554
555 * numbers.c: Define NO_PREPRO_MAGOC when including
556 num2integral.c.i for `long long' and `signed long long'.
557
152812c0
MD
5582001-10-06 Mikael Djurfeldt <mdj@linnaeus>
559
560 These changes fixes a race condition in the Guile coop - pthread
561 compatibility code.
d6b8cf11 562
152812c0
MD
563 * coop.c (mother_awake_p): New variable.
564 (coop_create): Set mother_awake_p before creating or signalling
565 mother; wait until mother is going to sleep before returning.
566 (mother): Reset mother_awake_p before going to sleep.
567
11d49f54
DH
5682001-10-05 Dirk Herrmann <D.Herrmann@tu-bs.de>
569
570 * options.c (protected_objects, scm_init_options): The content of
571 protected_objects is now protected from garbage collection using
572 scm_gc_register_root instead of scm_permanent_object.
573
574 (get_option_setting): New static function that computes an option
575 setting as it was formerly done in the function scm_options.
576
577 (get_documented_option_setting): New static function that
578 returns option documentation as it was formerly done in the
579 function scm_options. Note that documentation C strings are no
580 longer precomputed into SCM objects. Instead, they are converted
581 into SCM strings every time get_documented_option_setting is
582 called.
583
584 (change_option_setting): New static functions that modifies the
585 option setting as it was formerly done in the function
586 scm_options. The function is now exception safe, i. e. won't
587 cause a memory leak when interrupted. Further, only non-immediate
588 option values are added to the protection list.
589
590 (scm_options): This function now has only the purpose to dispatch
591 to to get_option_setting, get_documented_option_setting or
592 change_option_setting, depending on the arguments given to
593 scm_options.
594
595 (scm_init_opts): Don't convert documentation C strings into SCM
596 strings. Further, don't protect any object values: They _must_
597 be immediate values, otherwise there is no guarantee that they
598 have not been collected before anyway.
599
600 * options.[ch] (scm_t_option): Made type unsigned, name into a
601 constant char* and val into a scm_t_bits type.
602
603 (scm_options, scm_init_opts): The number of options is guaranteed
604 to be larger or equal to zero. Thus, the type is changed to
605 unsigned.
606
3dbacabc
DH
6072001-10-05 Dirk Herrmann <D.Herrmann@tu-bs.de>
608
609 * num2integral.i.c (NUM2INTEGRAL): Eliminated some warnings about
610 testing an unsigned value for being >= 0.
611
14282d0f
DH
6122001-10-05 Dirk Herrmann <D.Herrmann@tu-bs.de>
613
614 * numbers.h: Removed old comment about using SCM_CAR to access
615 non-pair cells.
616
617 (SCM_MOST_POSITIVE_FIXNUM, SCM_MOST_NEGATIVE_FIXNUM): Make sure
618 the return value is signed. Thanks to Brian Crowder for the bug
619 report.
620
621 (SCM_SRS): Avoid unnecessary casting and don't unpack input
622 values. With this patch, SCM_SRS can be safely used for other
623 types than scm_t_signed_bits. However, it should still better be
624 an internal macro and thus be renamed to SCM_I_SRS.
625
626 (SCM_MAKINUM, SCM_INUM): Use proper casting.
627
2dbec7b5
GH
6282001-10-03 Gary Houston <ghouston@arglist.com>
629
630 * continuations.h, unif.h: in the descriptions of the bit patterns
631 of the heap cells, make bit 0 the least significant.
632
cf4ee841
TTN
6332001-09-25 Thien-Thi Nguyen <ttn@glug.org>
634
635 * chars.h (SCM_MAKE_CHAR): Use `scm_t_bits' instead of `intptr_t'.
636 Thanks to Golubev I. N.
637
4a151b3d
GH
6382001-09-25 Gary Houston <ghouston@arglist.com>
639
640 * ports.c (scm_drain_input): extended the docstring. thanks to
641 Alex Schroeder and Thien-Thi Nguyen.
642
581ded70
MD
6432001-09-23 Mikael Djurfeldt <mdj@linnaeus>
644
645 * validate.h (SCM_NUM2FLOAT, SCM_NUM2DOUBLE,
646 SCM_VALIDATE_FLOAT_COPY, SCM_VALIDATE_DOUBLE_COPY): New
647 macros. (The NUM names might soon change.)
648
649 * numbers.h: Added missing declarations.
650
5437598b
MD
6512001-09-22 Mikael Djurfeldt <mdj@linnaeus>
652
653 * Makefile.am: Distribute num2float.i.c.
654
655 * num2float.i.c: New file, multiply included by numbers.c, used
656 to "templatize" the float <-> num conversion routines.
657
658 * numbers.c: New functions: scm_num2float, scm_float2num,
659 scm_num2double, scm_double2num.
660
0b073f0f
RB
6612001-09-21 Rob Browning <rlb@defaultvalue.org>
662
663 * .cvsignore: really add version.h
664
665 * strings.h (SCM_SET_STRING_LENGTH): coerce "l" to a long.
666 Otherwise it fails on the alpha. However, we might rather choose
667 this size conditionally.
668
669 * numbers.c (scm_gcd): change "k" to a long from an int.
670 Otherwise it fails on the alpha. However, we might rather choose
671 this size conditionally.
672
673 * error.c (scm_wta): coerce char* to intptr_t before int
674 assignment.
675
676 * debug.c (debugobj_print): coerce scm_intprint arg 1 to long, not
677 int.
678
679 * chars.h (SCM_MAKE_CHAR): coerce value to intptr_t.
680
2830fd91
MD
6812001-09-20 Mikael Djurfeldt <mdj@linnaeus>
682
683 * numbers.c (scm_integer_expt): Accept inexact integer in second
684 argument. (Thanks to Bill Schottstaedt.)
685
c13f0a90
RB
6862001-09-20 Rob Browning <rlb@defaultvalue.org>
687
688 * .cvsignore: add version.h
689
690 * versiondat.h.in: removed (obsolete).
691
692 * version.h.in: renamed from version.h.
693 (SCM_GUILE_MAJOR_VERSION): new public macro.
694 (SCM_GUILE_MINOR_VERSION): new public macro.
695 (SCM_GUILE_MICRO_VERSION): new public macro.
696
697 * version.h: renamed to version.h.in.
698
699 * version.c
700 (scm_major_version): support integer *_VERSION macros.
701 (scm_minor_version): support integer *_VERSION macros.
702 (scm_micro_version): support integer *_VERSION macros.
703 (scm_version): support integer *_VERSION macros.
704
147c18a0
MD
7052001-09-20 Mikael Djurfeldt <mdj@linnaeus>
706
707 * error.c, error.h: Made error keys globally accessible.
708 Applications might want to test for these or use them in a direct
709 call to scm_error.
710
711 * num2integral.i.c (NUM2INTEGRAL): Report an error when these
712 routines are passed an inexact. This change in behavior is
713 motivated by concordance with R5RS: It is more common that a
714 primitive doesn't want to accept an inexact for an exact.
715
662c5539
DH
7162001-09-17 Dirk Herrmann <D.Herrmann@tu-bs.de>
717
718 The following patch partially undoes my patch from 2001-06-30,
719 where I added the function scm_gc_mark_cell_conservatively. The
720 function is buggy, since it breaks guile during conservative
721 marking if a pointer on the stack points directly into the list of
722 free cells on the heap: With conservative cell marking this will
723 cause the whole free list to be scanned and marked - boom!
724
725 * gc.c (allocated_mark, MARK, heap_segment,
726 scm_gc_mark_cell_conservatively, scm_init_storage), gc.h
cf4ee841 727 (scm_gc_mark_cell_conservatively): Remove function
662c5539
DH
728 scm_gc_mark_cell_conservatively and update the corresponding
729 comments and uses accordingly. Thanks to Christopher Cramer for
730 the patch. (Minor corrections by me.)
731
6c1b7628
GH
7322001-09-15 Gary Houston <ghouston@arglist.com>
733
734 * root.h (scm_root_state): removed the continuation_stack and
735 continuation_stack_ptr members, which have no apparent purpose.
736 (scm_continuation_stack, scm_continuation_stack_ptr): #defines
737 removed.
662c5539 738
6c1b7628
GH
739 * root.c (root_mark), init.c (restart_stack, start_stack), gc
740 (scm_igc): remove all references to contination_stack and
741 continuation_stack_ptr, avoiding allocation of a vector and
742 useless processing during gc.
743
455c0ac8
DH
7442001-09-13 Dirk Herrmann <D.Herrmann@tu-bs.de>
745
746 * guardians.c (tconc_t, t_tconc): Renamed tconc_t to t_tconc.
747
748 (TCONC_IN): Make sure that the cell word 0 is initialized last.
749
750 (guardians_t, t_guardians): Renamed guardians_t to t_guardians.
751
752 (GUARDIAN, GUARDIAN_DATA): Renamed GUARDIAN to GUARDIAN_DATA.
753
754 (guardian_apply, scm_get_one_zombie, scm_make_guardian,
755 mark_and_zombify): Prefer !SCM_<foo> over SCM_N<foo>.
756
22ba637b
DH
7572001-09-13 Dirk Herrmann <D.Herrmann@tu-bs.de>
758
759 * guardians.c (mark_dependencies_in_tconc,
760 whine_about_self_centered_zombies, scm_init_guardians): Register
761 the static global variable `self_centered_zombies' via
762 scm_gc_register_root, to make some cdr-ing unnecessary.
763
c3c4d801
DH
7642001-09-13 Dirk Herrmann <D.Herrmann@tu-bs.de>
765
766 * backtrace.c (display_backtrace_file,
767 display_backtrace_file_and_line): Use SCM_EQ_P when comparing SCM
768 values, use SCM_FALSEP when comparing SCM values against #f.
769 Thanks to Rob Browning for the bug report.
770
b00418df
DH
7712001-09-12 Martin Baulig <martin@home-of-linux.org>
772
773 * strings.[ch] (scm_str2string): New function.
774
a0d34a0b
MV
7752001-09-06 Marius Vollmer <mvo@zagadka.ping.de>
776
777 * gc.c (scm_done_free): Always subtract size from scm_mallocated
778 when computing nm, even if it's negative.
779 (scm_must_malloc): Abort on overflow of scm_mtrigger.
780 (scm_must_realloc): Likewise.
781
b10586f0
ML
7822001-09-01 Michael Livshin <mlivshin@bigfoot.com>
783
784 * numbers.c (scm_sys_check_number_conversions): new function,
785 defined if Guile is compiled in debugging mode. currently checks
786 `scm_num2ulong', should check much much more.
787
788 * num2integral.i.c (NUM2INTEGRAL): when converting a bignum to
789 unsigned, ensure that it's positive. thanks to Martin Baulig!
cf4ee841 790
8c494e99
DH
7912001-08-31 Dirk Herrmann <D.Herrmann@tu-bs.de>
792
793 * __scm.h: Added new section about compile time selectable
794 features.
795
796 (long_long, ulong_long, scm_sizet, SCM_WNA, SCM_OUTOFRANGE,
797 SCM_NALLOC, SCM_HUP_SIGNAL, SCM_INT_SIGNAL, SCM_FPE_SIGNAL,
798 SCM_BUS_SIGNAL, SCM_SEGV_SIGNAL, SCM_ALRM_SIGNAL, SCM_GC_SIGNAL,
799 SCM_TICK_SIGNAL, SCM_SIG_ORD, SCM_ORD_SIG, SCM_NUM_SIGS):
800 Removed.
801
802 * deprecation.c (scm_include_deprecated_features): Simplified.
803
804 * eval.c (EVALCAR, unmemocopy), eval.h (SCM_XEVALCAR): Use
805