1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-05-05 06:50:21 +02:00
Commit graph

3667 commits

Author SHA1 Message Date
Gary Houston
69bc9ff335 1999-07-24 Gary Houston <ghouston@easynet.co.uk>
* gdbint.c (gdb_print, gdb_read): call scm_truncate_file.

	* ports.c (scm_truncate_file): renamed from scm_ftruncate.
	allow the 1st argument to be a fdes or filename as well as a
	port (as in the filesys.c version).

	* filesys.c (scm_truncate_file): removed.
1999-07-24 19:52:13 +00:00
Mikael Djurfeldt
2179c70cf4 Regenerated 1999-07-24 11:51:24 +00:00
Mikael Djurfeldt
096d0b15f6 *** empty log message *** 1999-07-24 11:39:36 +00:00
Mikael Djurfeldt
3469affdff * readline.c, readline.h: Removed. 1999-07-24 11:37:12 +00:00
Mikael Djurfeldt
d0efbe6199 * objects.c, objects.h (scm_port_class): Added.
(scm_class_of): Look up port class in scm_port_class.
(SCM_IN_PCLASS_INDEX, SCM_OUT_PCLASS_INDEX,
SCM_INOUT_PCLASS_INDEX): Added.
1999-07-24 11:36:30 +00:00
Mikael Djurfeldt
aafe2718aa *** empty log message *** 1999-07-23 13:14:20 +00:00
Mikael Djurfeldt
b505860d29 * init.c: Make sure that scm_post_boot_init_modules is called only
once.  (Important when using a dumped image.; Thanks to Bernard
Urban.)
1999-07-23 13:14:05 +00:00
Jim Blandy
8e1e60f181 *** empty log message *** 1999-07-19 18:57:40 +00:00
Jim Blandy
67b2561b50 * guardians.c (scm_guardian_zombify): Separate scanning for
zombies from marking the pairs of the free list.
1999-07-19 18:57:02 +00:00
Jim Blandy
a825bb0e2d *** empty log message *** 1999-07-19 18:46:09 +00:00
Jim Blandy
55b7e0bd82 * guardians.c (scm_guardian_zombify): Don't set marks manually ---
use the macros.  (Thanks to Michael Livshin.)
1999-07-19 18:45:57 +00:00
Jim Blandy
4d4c53aca7 *** empty log message *** 1999-07-19 08:59:30 +00:00
Jim Blandy
a42f00b823 * stime.c (ftime): Delete declaration for this function --- let
the system supply it.
1999-07-19 08:58:42 +00:00
Jim Blandy
ae904cfae3 * eval.c (scm_m_lambda): Let bodycheck check the body of the
lambda.  Let your sins be purified by the blood of the lambda.
(Thanks to Eric Hanchrow.)
1999-07-19 08:45:54 +00:00
Jim Blandy
a122f2f9ea *** empty log message *** 1999-07-19 08:22:28 +00:00
Jim Blandy
d9ad691916 *** empty log message *** 1999-07-19 08:20:44 +00:00
Jim Blandy
e6393a4a0c * net_db.c (h_errno): Don't declare this if it's #defined. Eew.
(Thanks to Valdis Kletnieks.)
1999-07-19 08:20:27 +00:00
Jim Blandy
3144e1a9e9 *** empty log message *** 1999-07-19 07:54:37 +00:00
Jim Blandy
b89b25edd2 * tags.h (SCM_IMP, SCM_NCONSP, SCM_NCELLP, SCM_ITAG3, SCM_TYP3,
SCM_TYP7, SCM_TYP7S, SCM_TYP16, SCM_TYP16S, SCM_GCTYP16,
SCM_GCMARKP, SCM_GC8MARKP): Don't cast to int.  Either SCM or no
cast at all is more appropriate in every case.  At the moment, we
assume everywhere that SCM is an integral type anyway.
1999-07-19 07:54:12 +00:00
Jim Blandy
af68fb843b * snarf.h (SCM_CONST_LONG): Remove trailing semicolon from
definition.
1999-07-19 07:53:51 +00:00
Jim Blandy
8638b0979a * scmsigs.c (scm_sigaction): Cast SIG_DFL and SIG_IGN to SCM, not
int.  That way, if we get a warning on this line, it's more likely
that we're really missing bits we care about.
1999-07-19 07:53:21 +00:00
Jim Blandy
435220a73c * regex-posix.c (scm_regexp_error_msg): Change `rx' argument to
regex_t pointer.  This is what the callers have, mostly.
(scm_regexp_exec): Don't forget to pass the `rx' argument to
scm_regexp_error_msg.
1999-07-19 07:52:51 +00:00
Jim Blandy
62f36a0d27 * gdbint.c: Don't include <stdio.h> and "_scm.h" twice.
* gsubr.c: Don't include "gsubr.h" twice.
1999-07-19 07:52:07 +00:00
Jim Blandy
def804a381 * filesys.c: #include <io.h>, if we have it.
* scmconfig.h.in: Regenerated.
1999-07-19 07:49:58 +00:00
Jim Blandy
131f97a979 Regenerated. 1999-07-19 07:42:33 +00:00
Jim Blandy
0c2b93ddf4 *** empty log message *** 1999-07-17 18:43:17 +00:00
Jim Blandy
37a33fed28 Patch from Greg Badros:
* snarf.h (SCM_PROC, SCM_PROC1): Use __cplusplus or
GUILE_CPLUSPLUS_SNARF macros to force adding a cast to the last
(function pointer) argument to scm_make_gsubr and scm_make_subr
calls.  This avoids warnings in C++ programs using guile-snarf.
1999-07-17 05:49:20 +00:00
Gary Houston
5c070ca7fd 1999-07-14 Gary Houston <ghouston@easynet.co.uk>
* unif.c (scm_uniform_array_read_x), ports.c (scm_getc): increment
	read_pos after scm_fill_buffer.
	* ioext.c (scm_do_read_line): simplify by ignoring the fill_buffer
	return char.
	* vports.c (sf_fill_buffer), strports.c (stfill_buffer),
	fports.c (fport_fill_buffer): implement the interface change.
	* ports.c (scm_fill_buffer): interface change: no longer increments
	read_pos past the character that's returned.  it seems clearer to
	leave it to the caller to decide what to do (thanks Jim).
	* vports.c (sf_fill_buffer): put the read char into the buffer
	as well as returning it.
	* ports.c (scm_grow_port_cbuf): residue of this deleted procedure
	deleted.
1999-07-14 13:55:01 +00:00
Gary Houston
3fe6190f46 1999-07-13 Gary Houston <ghouston@easynet.co.uk>
* strports.c (scm_strprint_obj): simplify.  start with initial
	buffer size of 0.
	(st_seek): don't allow string to be extended if seeking past
	the end of a read-only port.
1999-07-12  Gary Houston  <ghouston@easynet.co.uk>
	* strports.c (st_seek): change the resize checks.
	* ports.c (scm_ftruncate): throw error if offset works out negative.
	* strports.c (st_flush): increase string size in blocks of
	SCM_WRITE_BLOCK instead of 1. set read_end to read_pos if
	it's greater and reset read_buf_size.
	(scm_mkstrport): set rw_randow if only writing, since read_buf needs
	to be maintained for output ports too (it holds the written
	part of the string, while write_buf may have unwritten buffer
	chars.)
	(st_truncate): rewritten.
	(top of file): added a few notes.
1999-07-06  Gary Houston  <ghouston@easynet.co.uk>
	* strports.c (st_grow_port): set pt->read_pos.  set
	pt->read_buf_size one less than pt->write_buf_size if there's
	an unwritten char at the end of the string.  similarly for
	pt->read_end.
	(st_resize_port): renamed from st_grow_port.
	(st_seek): simplify by assuming that pt->write_pos == pt->read_pos.
	seek from read_end instead of write_end for SEEK_END.
	(st_ftruncate): calculate current length using readbuf, not write
	buf.
	(scm_strport_to_string): use read_buf_size for length.
	(stfill_buffer): don't re-initialise the readbuf.
1999-07-05  Gary Houston  <ghouston@easynet.co.uk>
	* strports.c (scm_strport_to_string): new procedure.
	(scm_call_with_output_string, scm_strprint_obj): use
	scm_strport_to_string.
	used SCM_INUM0 instead of SCM_MAKINUM (0) in a few places.
1999-07-13 11:06:18 +00:00
Mikael Djurfeldt
4dc7f07fde *** empty log message *** 1999-07-08 05:58:11 +00:00
Mikael Djurfeldt
aea5b792f7 * symbols.c (scm_gensym): Bugfix. (Thanks to Johannes Hjorth.) 1999-07-08 05:55:34 +00:00
Mikael Djurfeldt
544b923292 *** empty log message *** 1999-07-07 09:44:53 +00:00
Mikael Djurfeldt
23a621512f Greg's smob patch 1999-07-07 09:44:01 +00:00
Gary Houston
283a1a0e77 1999-07-04 Gary Houston <ghouston@easynet.co.uk>
* unif.c (scm_uniform_array_write): likewise.
	* ioext.c (scm_redirect_port): likewise.
	* ports.c (scm_putc): call scm_read_flush.
	(scm_puts): likewise.
	(scm_lfwrite): likewise.
	(scm_lseek): likewise.
	(scm_ftruncate): likewise.
	* ports.c (scm_fill_buffer): don't take pt argument.  change callers.
	(read_flush_void_port): new proc, for void port ptob.
	* vports.c (sf_read_flush): likewise.
	* strports.c (st_read_flush): take offset arg.
	* fports.c (local_read_flush): use offset, don't reset putback
	buffer here.
	* ports.h (scm_ptobfuns): let read_flush take an offset argument,
	which is the number of chars from the putback buffer.
	* ports.c (scm_read_flush): new procedure, resets the putback
	buffer before calling the ptob routine.
1999-07-04 11:50:54 +00:00
Gary Houston
6c9514275b 1999-07-04 Gary Houston <ghouston@easynet.co.uk>
* strports.c (scm_strprint_obj): bug fix: get pt from the port,
	not from the parameter obj.  (Thanks to Eric Moore.)
	* ports.h: SCM_CRDY, SCM_CUC, SCM_CRDYP, SCM_SETRDY, SCM_CUNGET,
	SCM_CGETUN, SCM_CLRDY, SCM_TRY_CLRDY, SCM_N_READY_CHARS: deleted.
	* strings.c (scm_make_string): throw error if 2nd arg isn't
	a char.
	* unif.c (scm_uniform_array_read_x): fix reading from a port.
	allow non-fports.
	(scm_uniform_array_write): likewise.
1999-06-29  Gary Houston  <ghouston@easynet.co.uk>
	* ports.c (scm_drain_input): rewritten.
	* fports.c (local_fclose): check putback_buf.
	(local_read_flush): likewise.
	* ports.c (scm_remove_from_port_table): maybe free putback_buf.
	* ports.h (scm_port): replace cbuf/cbufend/cp with putback_buf/
	putback_buf_size.
	(SCM_INITIAL_PUTBACK_BUF_SIZE): renamed from SCM_INITIAL_CBUF_SIZE.
	* ports.c (scm_grow_port_cbuf): deleted.
	(scm_add_to_port_table): initialise putback_buf to 0.  remove cbuf
	stuff.
	(scm_char_ready_p): check putback_buf
	(scm_fill_buffer): likewise.
	(scm_ungetc): rewritten.
1999-06-27  Gary Houston  <ghouston@easynet.co.uk>
	* fports.c (local_fclose): account for push-back buffer.
	* ports.c (scm_char_ready_p): check the push-back buffer in
	a new way.
	* ioext.c (scm_do_read_line): remove the extra code to handle
	the push-back buffer.
	* ports.c (scm_getc): don't use SCM_CRDYP etc.
	* ioext.c (scm_do_read_line): call scm_fill_buffer.
	* ports.c (scm_ungetc): don't call SCM_CUNGET.  reset the
	read buffer pointers.
	scm_fill_buffer: new procedure.
	(scm_getc): call scm_fill_buffer.
	* ports.h (struct scm_port): saved_read_buf, saved_read_pos,
	saved_read_end: new fields.
1999-07-04  Gary Houston  <ghouston@easynet.co.uk>
	* configure.in: don't check for ways to violate stdio abstraction.
1999-07-04 11:02:21 +00:00
Mikael Djurfeldt
0af045dfe5 *** empty log message *** 1999-06-23 16:00:30 +00:00
Mikael Djurfeldt
af1f9aa293 * dynl-dl.c (sysdep_dynl_link): Added parenthesis around the
trinary conditional in order for the flag computation to be
correct.
1999-06-23 16:00:15 +00:00
Mikael Djurfeldt
8b5af48ab1 *** empty log message *** 1999-06-23 11:19:45 +00:00
Mikael Djurfeldt
ff2961ec2c * tag.c (scm_tag): Base tag on vtable pointer. 1999-06-23 11:19:25 +00:00
Mikael Djurfeldt
ad1965993e * struct.c, struct.h:
(scm_struct_i_free): New hidden struct slot.  Holds destructor for
instances to this vtable.
(scm_struct_free_0): New destructor: Doesn't deallocate data.
(scm_struct_free_light): New destructor: Deallocates a light
struct (i.e. a struct without hidden slots).
(scm_struct_free_standard): New destructor: Deallocates standard
structs.
(scm_struct_free_entity): New destructor: Deallocates entity
structs.
(SCM_SET_VTABLE_DESTRUCTOR): New macro.
Changes to hidden slots:
(scm_struct_i_size): scm_struct_i_flags now shares space with
scm_struct_i_size which holds the size of light structs.
(scm_struct_i_n_words): This slot has changed meaning.  Previously
it included hidden slots.  Now it indicates visible slots.
(scm_alloc_struct): Clear flags.
(SCM_STRUCTF_MASK): 4 new flag positions added => 12 bits.
(struct_num, scm_struct_i_tag): Removed.
(scm_struct_vtable_tag): Base tag on the pointer to mallocated
memory.
(scm_struct_ihashq): Base hash value on pointer to struct handle.
1999-06-23 11:17:36 +00:00
Mikael Djurfeldt
37b83f68b0 * snarf.h (SCM_KEYWORD, SCM_GLOBAL_KEYWORD): New macros. 1999-06-23 11:16:52 +00:00
Mikael Djurfeldt
2eafbe52c6 * objects.h (SCM_SET_CLASS_DESTRUCTOR,
SCM_SET_CLASS_INSTANCE_SIZE): New macros.
1999-06-23 11:16:44 +00:00
Mikael Djurfeldt
135e76f876 * objects.c (scm_init_objects): Initialize destructor slot of the
primordial entity class.
1999-06-23 11:16:28 +00:00
Mikael Djurfeldt
d6af5a438b * libguile.h: #include "objects.h" 1999-06-23 11:16:18 +00:00
Mikael Djurfeldt
430a6cc34e * keywords.c, keywords.h (scm_c_make_keyword): New function.
(We should remove the use of the prefix '-'.)
1999-06-23 11:16:09 +00:00
Mikael Djurfeldt
f0cb1733dd * gc.c (scm_gc_sweep): Call struct free slot. 1999-06-23 11:15:58 +00:00
Marius Vollmer
3f737ec81d *** empty log message *** 1999-06-21 15:18:48 +00:00
Marius Vollmer
8e3ab00333 Resolved harmless conflict. 1999-06-21 15:16:54 +00:00
Marius Vollmer
56a19408b8 * dynl.c (DYNL_GLOBAL): New.
(sysdep_dynl_link): Added `flags' argument.
(kw_global, sym_global): New.
(scm_dynamic_link): Handle keyword arguments.  Pass suitable flags
to sysdep_dynl_link.
* dynl-dl.c (sysdep_dynl_link): Handle new `flags' argument by
conditrionally adding RTLD_GLOBAL to DLOPEN_MODES.
* dynl-shl.c (sysdep_dynl_link): Add and ignore new flags
argument.
* dynl-dld.c (sysdep_dynl_link): Add and ignore new flags
argument.
* dynl.h (scm_dynamic_link): Added rest argument.
* dynl.c (sysdep_dynl_unlink, sysdep_dynl_func): Use const
qualifier for char* argument, to match prototypes.  Thanks to Mark
Elbrecht.
1999-06-21 15:14:01 +00:00
Jim Blandy
56ef2fe230 *** empty log message *** 1999-06-21 14:50:36 +00:00