1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-05-05 15:10:27 +02:00
Commit graph

3667 commits

Author SHA1 Message Date
Mikael Djurfeldt
fa941d9e36 *** empty log message *** 1999-08-30 12:27:29 +00:00
Jim Blandy
ebc4e6cc6a *** empty log message *** 1999-08-30 07:02:46 +00:00
Jim Blandy
aa97ff6036 * gh_data.c (gh_set_substr): Revert change of 1999-08-29; bcopy is
not a correct substitute for memmove, because it doesn't handle
overlapping source and destination areas on many platforms.
Overlaps are the primary reason to use memmove in the first place.
* ports.c (scm_ungetc): Same.
* strop.c (scm_substring_move_x): Same.
1999-08-30 07:02:25 +00:00
Mikael Djurfeldt
55861efad5 Regenerated 1999-08-30 02:49:35 +00:00
Mikael Djurfeldt
0824bbb3f5 Moved scm_memoize_method back to eval.c. 1999-08-30 02:18:35 +00:00
Mikael Djurfeldt
61364ba686 * eval.c (SCM_CEVAL): Duplicated the method dispatch code at the
SCM_IM_DISPATCH form instead of calling scm_mcache_lookup_cmethod
since that cuts down the time for type dispatch by 50%.
1999-08-30 02:18:00 +00:00
Mikael Djurfeldt
a709833577 *** empty log message *** 1999-08-30 02:15:07 +00:00
Mikael Djurfeldt
97056309c3 * struct.c, struct.h (scm_struct_free_0, scm_struct_free_light,
scm_struct_free_standard, scm_struct_free_entity): Declared to
return scm_sizet instead of size_t.
1999-08-30 02:14:47 +00:00
Mikael Djurfeldt
681b900590 * gdbint.c, strports.c: #include <unistd.h>. (SEEK_SET is defined
there on sunos4.1.4.)
1999-08-30 02:14:36 +00:00
Mikael Djurfeldt
a18bcd0e5f * gc.c (scm_init_storage): Skip registration of cleanup on systems
which lack atexit.  (Is it important that cleanup is made
properly? Maybe we should replace all `exit' with `scm_exit' and
call cleanup there?)
1999-08-30 02:13:45 +00:00
Mikael Djurfeldt
87fbf1be91 Fix of last fix 1999-08-29 19:26:53 +00:00
Mikael Djurfeldt
747117b018 *** empty log message *** 1999-08-29 18:32:24 +00:00
Mikael Djurfeldt
9a26d6f91e *** empty log message *** 1999-08-29 18:17:58 +00:00
Mikael Djurfeldt
02a3305a85 * numbers.c (scm_lcm): Bugfix: BIGDIG --> SCM_BIGDIG;
Account for the case when second argument is unbound.
1999-08-29 18:15:09 +00:00
Mikael Djurfeldt
dd054d4138 * strorder.c (scm_string_less_p, scm_string_ci_less_p): Bugfix.
(Thanks to Karoly Lorentey.)
1999-08-29 18:04:55 +00:00
Mikael Djurfeldt
c1c6aa4b20 Regenerated 1999-08-29 18:04:43 +00:00
Mikael Djurfeldt
a284e29725 * gh_data.c, ports.c, strop.c: Alternatively use bcopy if memmove
isn't present.  (Thanks to suzukis@file.phys.tohoku.ac.jp.)

* ports.c: Use ANSI C prototypes in definitions.  (Thanks to
Bernard Urban.)
1999-08-29 18:04:28 +00:00
Mikael Djurfeldt
5e860ea7e2 * gh_data.c, ports.c, strop.c: Alternatively use bcopy if memmove
isn't present.  (Thanks to suzukis@file.phys.tohoku.ac.jp.)
1999-08-29 18:04:11 +00:00
Mikael Djurfeldt
f326ecf386 * filesys.c (scm_stat2scm): Conditionally use S_ISLNK. 1999-08-29 18:03:39 +00:00
Mikael Djurfeldt
7671d04a38 * dynl-dl.c (RTLD_GLOBAL): Define if non-existent. (Thanks to
Bernard Urban and Ian Grant.)
1999-08-29 18:03:26 +00:00
Mikael Djurfeldt
5d175eaff0 * Makefile.am (libguile_la_LDFLAGS): Bumped libguile version
again.  (1.3.4 will be binary incompatible with 1.3.2 because of a
change in the representation of entities and operators.)
1999-08-29 18:03:02 +00:00
Gary Houston
5c4fe34f92 add the attribution 1999-08-29 16:54:34 +00:00
Gary Houston
6e2e75db52 1999-08-29 Gary Houston <ghouston@easynet.co.uk>
* ports.c (scm_ungetc): bugfix: if putback_buf is NULL
	don't allocate zero bytes.
1999-08-29 16:50:40 +00:00
Mikael Djurfeldt
a48a7629fc *** empty log message *** 1999-08-29 14:24:24 +00:00
Mikael Djurfeldt
c242a86327 * stacks.c (scm_sym_apply): Removed. (Thanks to Ken Raeburn.) 1999-08-29 14:22:59 +00:00
Mikael Djurfeldt
f52672312e * procs.c (scm_setter): Converted to use generic dispatch. 1999-08-29 14:22:44 +00:00
Mikael Djurfeldt
0a74e31d21 * load.c (scm_search_path): Don't try extensions which already are
present at the end of the filename.
(scm_init_load): Check .scm first. (Thanks to Keisuke Nishida.)
1999-08-29 14:22:29 +00:00
Mikael Djurfeldt
81123e6d05 * eval.c, eval.h: Bugfix: scm_sym_apply was not initialized
correctly.
1999-08-29 14:22:16 +00:00
Mikael Djurfeldt
c5b738b500 *** empty log message *** 1999-08-29 03:29:03 +00:00
Mikael Djurfeldt
a9571599e7 * tags.h (SCM_IM_HASH_DISPATCH): Removed. 1999-08-29 03:28:08 +00:00
Mikael Djurfeldt
2c53acd5c3 * struct.c, struct.h: Replace 4 procedure slots with one.
(scm_struct_i_procedure): Replaces scm_struct_i_procedure.
1999-08-29 03:27:55 +00:00
Mikael Djurfeldt
4c6fe5fca5 Fix 1999-08-29 03:27:33 +00:00
Mikael Djurfeldt
815ce8d58a * procprop.c (scm_i_procedure_arity): Bugfix: Handle generics. 1999-08-29 03:27:18 +00:00
Mikael Djurfeldt
f4250a95f9 * print.c (scm_isymnames): Removed #@hash-dispatch. 1999-08-29 03:27:07 +00:00
Mikael Djurfeldt
e34e12f00a * objects.c, objects.h (scm_mcache_lookup_cmethod): Moved here
from eval.c; Support 0 arity methods.
(scm_set_object_procedure_x): Removed scm_sym_atdispatch;
(scm_apply_generic_env): Removed.
Replaced slots proc0-3 with procedure.

* objects.h (SCM_OPERATOR_PROC_0, SCM_OPERATOR_PROC_1,
SCM_OPERATOR_PROC_2, SCM_OPERATOR_PROC_3): Replaced by
SCM_OPERATOR_PROCEDURE.
(SCM_ENTITY_PROC_0, SCM_ENTITY_PROC_1, SCM_ENTITY_PROC_2,
SCM_ENTITY_PROC_3): Replaced by SCM_ENTITY_PROCEDURE.
1999-08-29 03:26:51 +00:00
Mikael Djurfeldt
a12be5461e * objects.c, objects.h (scm_mcache_lookup_cmethod): Moved here
from eval.c; Support 0 arity methods.
(scm_set_object_procedure_x): Removed scm_sym_atdispatch;
(scm_apply_generic_env): Removed.
Replaced slots proc0-3 with procedure.
1999-08-29 03:26:38 +00:00
Mikael Djurfeldt
73e10adf20 * gc.c (scm_gc_mark): Mark 1 procedure slot in entities instead of
4.
1999-08-29 03:26:21 +00:00
Mikael Djurfeldt
195847fa2a * eval.c (scm_sym_args): Removed.
(SCM_CEVAL): Simplified entity application.
Moved dispatch code to objects.c.
1999-08-29 03:26:05 +00:00
Mikael Djurfeldt
375c11a331 *** empty log message *** 1999-08-29 01:31:09 +00:00
Mikael Djurfeldt
342490251d * sort.c (closureless): Use scm_eval_body. 1999-08-29 01:29:05 +00:00
Mikael Djurfeldt
e791c18fbb * eval.c (SCM_APPLY): Fixed serious evaluator bug which returned
an ILOC instead of the value if a closure with a symbol as last
form was first called normally and then via `map'.
1999-08-29 01:28:49 +00:00
Mikael Djurfeldt
9de33deb2e * procs.c, procs.h (scm_subr_entry): New type: Stores data
associated with subrs.
(SCM_SUBRNUM, SCM_SUBR_ENTRY, SCM_SUBR_GENERIC, SCM_SUBR_PROPS,
SCM_SUBR_DOC): New macros.
(scm_subr_table): New variable.
(scm_mark_subr_table): New function.

* init.c (scm_boot_guile_1): Call scm_init_subr_table.

* gc.c (scm_gc_mark): Don't mark subr names here.
(scm_igc): Call scm_mark_subr_table.

* snarf.h (SCM_GPROC, SCM_GPROC1): New macros.

* procs.c, procs.h (scm_subr_p): New function (used internally).

* gsubr.c, gsubr.h (scm_make_gsubr_with_generic): New function.

* objects.c, objects.h (scm_primitive_generic): New class.

* objects.h (SCM_CMETHOD_CODE, SCM_CMETHOD_ENV): New macros.

* print.c (scm_iprin1): Print primitive-generics.

* __scm.h (SCM_WTA_DISPATCH_1, SCM_GASSERT1,
SCM_WTA_DISPATCH_2, SCM_GASSERT2): New macros.

* eval.c (SCM_CEVAL, SCM_APPLY): Replace scm_wta -->
SCM_WTA_DISPATCH_1 for scm_cxr's (unary floating point
primitives).  NOTE: This means that it is now *required* to use
SCM_GPROC1 when creating float scm_cxr's (float scm_cxr's is an
obscured representation that will be removed in the future anyway,
so backward compatibility is no problem here).

* numbers.c: Converted most numeric primitives (all but bit
comparison operations and bit operations) to dispatch on generic
if args don't match.

* eval.c, eval.h (scm_eval_body): New function.

* objects.c (scm_call_generic_0, scm_call_generic_1,
scm_call_generic_2, scm_call_generic_3, scm_apply_generic): New
functions.

* eval.c (SCM_CEVAL): Apply the cmethod directly after having
called scm_memoize_method instead of doing a second lookup.

* objects.h (scm_memoize_method): Now returns the memoized cmethod.

* procs.c (scm_make_subr_opt): Use scm_sysintern0 instead of
scm_sysintern so that the binding connected with the subr name
isn't cleared when we give set = 0.
1999-08-26 04:24:42 +00:00
Mikael Djurfeldt
52235e7173 fix 1999-08-24 02:23:02 +00:00
Mikael Djurfeldt
079100140f *** empty log message *** 1999-08-24 02:14:57 +00:00
Mikael Djurfeldt
edf2049212 * print.h (SCM_PORT_WITH_PS_P, SCM_PORT_WITH_PS_PORT,
SCM_PORT_WITH_PS_PS): Represent ports with print states as a smob
instead of a pair of a port and a print state.  We'll need to cons
once extra in scm_printer_apply but the type system will be
cleaner, it will mix better with GOOPS, and, it will be even more
transparent to the user.
1999-08-24 02:12:06 +00:00
Mikael Djurfeldt
c19bc08823 * print.c (scm_get_print_state): New procedure: Given an output
port, return the print state associated to it in the current print
chain, if one exists;
(scm_port_with_print_state): New procedure: Associate a
print-state with a port.
(scm_valid_oport_value_p): Use SCM_PORT_WITH_PS_P;
(scm_printer_apply): Wrap port and pstate as a smob;
(print_state_printer): Removed.
1999-08-24 02:11:54 +00:00
Mikael Djurfeldt
4a94d8ca0b * ports.c (scm_output_port_p): Bugfix: Coerce output port before
testing (otherwise the port-print-state trick won't be transparent
to the user; one example where this caused problems was in the
(ice-9 format) module).
1999-08-24 02:11:17 +00:00
Mikael Djurfeldt
55d5475044 * objects.c (scm_class_of): Treat scm_tc16_port_with_ps as ports. 1999-08-24 02:10:47 +00:00
Mikael Djurfeldt
f99c9c2824 * eval.c (scm_init_eval): Use scm_make_smob_type instead of
scm_newsmob.
1999-08-24 02:10:19 +00:00
Mikael Djurfeldt
e2e470cf47 *** empty log message *** 1999-08-23 21:27:21 +00:00