1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-05-04 14:20:26 +02:00
Commit graph

3667 commits

Author SHA1 Message Date
Mikael Djurfeldt
8bb51def7d *** empty log message *** 1998-05-04 11:33:35 +00:00
Mikael Djurfeldt
eb545bd9b9 * procprop.h (scm_sym_arity): New symbol. 1998-05-04 11:33:14 +00:00
Mikael Djurfeldt
67e6065510 * procprop.c (scm_i_procedure_arity): New function. Returns arity
of procedure.
(scm_procedure_properties): Modified to return arity together with
other properties.
(scm_procedure_property): Added the read-only property `arity'.
(scm_set_procedure_property_x): It is an error to set the `arity'
property.
1998-05-04 11:32:58 +00:00
Mikael Djurfeldt
b6d850ad9c * objects.h (SCM_METACLASS_OPERATOR_LAYOUT, SCM_ENTITY_LAYOUT):
Made procedure slots read-only.
1998-05-04 11:32:44 +00:00
Mikael Djurfeldt
47b210500b * objects.c (scm_set_object_procedure_x): New procedure: Use this
to set the dispatch procedure of an operator or entity object.
1998-05-04 11:32:30 +00:00
Mikael Djurfeldt
dc0938d8a4 * gsubr.h, gsubr.c: Moved macros from gsubr.c to gsubr.h and added
prefix SCM_; Made f_gsubr_apply global and added prefix scm_.
1998-05-04 11:32:05 +00:00
Mikael Djurfeldt
65e417214c * eval.c (SCM_CEVAL): Moved scm_tc7_contin case above
scm_tcs_cons_gloc case in zero args switch; Fixed args
construction for operators in scm_tcs_cons_gloc case in two args
switch.
1998-05-04 11:31:45 +00:00
Mikael Djurfeldt
c716d9fcf2 Updated 1998-05-02 22:27:11 +00:00
Mikael Djurfeldt
104d453328 * fluids.c: Removed use of assert.h (in order to avoid
__eprintf).

* Makefile.am (libguile_la_LDFLAGS): Added -export-dynamic.

* dynl.c (maybe_drag_in_eprintf): Disabled through #ifdef 0.
1998-05-02 22:26:44 +00:00
Mikael Djurfeldt
680ed4a802 * eval.c (SCM_CEVAL): Do more thorough argument checking. This
change makes the evaluator safer at the cost of evaluation speed.
It handles the case when the user has added a non-immediate
improper end of the application form, e.g., `(+ 0 . x)'.
(Earlier only cases like `(+ 0 . 0)' were handled.)  I've tried to
minimize the extra cost as much as possible.  The new code is
enclosed in #ifdef CAUTIOUS regions.  NOTE: This also fixes the
problem with structs planted directly in the code (e.g. by a
macro).  This no longer causes segmentation fault.  (Thanks to
Eric Hanchrow.)

* eval.c, eval.h (scm_eval_args, scm_deval_args): Take one extra
arg `proc' in order to be able to throw errors; New argument
checking code.
1998-05-02 16:26:21 +00:00
Mikael Djurfeldt
2c36126d13 *** empty log message *** 1998-04-24 23:51:34 +00:00
Mikael Djurfeldt
0935d604b5 * scmsigs.c: Declare usleep as returning void on some systems.
(scm_usleep): Return SCM_INUM0 on those systems.

* coop.c (usleep): Return void on some systems.

* configure.in: Define USLEEP_RETURNS_VOID on some systems.
1998-04-24 23:36:04 +00:00
Mikael Djurfeldt
f1a5fa3c92 * Makefile.am (libguile_la_LDFLAGS): Removed redundant -rpath. 1998-04-20 00:40:43 +00:00
Mikael Djurfeldt
ce874f2db7 * scmsigs.c (scm_usleep): New procedure; Declare usleep if it
isn't found in the OS.
1998-04-20 00:40:09 +00:00
Mikael Djurfeldt
7105a806ee Updated 1998-04-20 00:39:59 +00:00
Mikael Djurfeldt
6d8d2debd7 * iselect.h: #define scm_internal_select select if GUILE_ISELECT
isn't enabled.  (Thought that I had made this change ages ago...)
1998-04-20 00:39:45 +00:00
Mikael Djurfeldt
b8ff5fe924 * iselect.c: Declare bzero if not defined by OS. 1998-04-20 00:39:31 +00:00
Mikael Djurfeldt
2c4e1a3484 * coop.c: Changed return type of usleep to int. 1998-04-20 00:39:15 +00:00
Mikael Djurfeldt
f83e27370c * continuations.c (scm_make_cont), debug.c (scm_make_memoized,
scm_make_debugobj), eval.c (scm_makprom): SCM_DEFER/ALLOW_INTS -->
A section.

* __scm.h: Start the long-term project of moving to POSIX threads.
Phase 1: Classification of all critical sections.
(SCM_ENTER_A_SECTION, SCM_EXIT_A_SECTION): New macros: Delimiters
for A sections.  (See comments in __scm.h for details.)
1998-04-19 20:16:36 +00:00
Mikael Djurfeldt
c3e09ef939 * dynl.c (scm_must_free_argv): Fixed memory leak due to negated
condition.  (Thanks to John Tobey.)

* dynl.c: Only check that HAVE_DLOPEN is defined before loading
dynl-dl.c; Test on HAVE_LIBDLD instead of HAVE_DLD.
1998-04-19 20:15:49 +00:00
Mikael Djurfeldt
9dca3959bd * dynl.c: Only check that HAVE_DLOPEN is defined before loading
dynl-dl.c; Test on HAVE_LIBDLD instead of HAVE_DLD.

* configure.in: Define HAVE_DLOPEN also when HAVE_LIBDL is
defined.
1998-04-19 01:17:26 +00:00
Mikael Djurfeldt
26c41b9956 * dynl.c: Only check that HAVE_DLOPEN is defined before loading
dynl-dl.c; Test on HAVE_LIBDLD instead of HAVE_DLD.

* configure.in: Define HAVE_DLOPEN also when HAVE_LIBDL is
defined.
1998-04-19 00:36:12 +00:00
Mikael Djurfeldt
28795b1f48 * script.c (scm_compile_shell_switches): Bugfix: Don't discount i
from argc if argc was 0 initially.
1998-04-18 21:58:47 +00:00
Mikael Djurfeldt
90ff3ec5f6 * Makefile.am (Makefile.am): Replaced THREAD_LIBS --> GUILE_LIBS
in generation of libpath.h.
1998-04-18 21:58:24 +00:00
Mikael Djurfeldt
daa4f38c59 * Makefile.am (BUILT_SOURCES): Added cpp_err_symbols.c,
cpp_sig_symbols.c, libpath.h and versiondat.h to BUILT_SOURCES
(libpath.h, versiondat.h): Replaced dependency on Makefile with
dependencies on $(srcdir)/Makefile.in
$(top_builddir)/config.status in order to avoid circularity.

* configure.in (GUILE_LIBS): New variable.  Contains libraries
which libguile needs to be linked with.  Substituted into
libpath.h.

* threads.m4 (threads_package): Don't add $LDFLAGS and $LIBS to
$cy_cv_threads_libs.
1998-04-18 21:57:32 +00:00
Mikael Djurfeldt
f2e5c92c98 * Makefile.am (libguile_la_LDFLAGS): Bumped version number of
libguile from 2 to 3.
1998-04-15 12:27:47 +00:00
Mikael Djurfeldt
a3365d4711 * Makefile.am: Added .x-dependencies to variable BUILT_SOURCES. 1998-04-14 09:22:52 +00:00
Mikael Djurfeldt
2c2b06709f Small fix. 1998-04-14 09:22:27 +00:00
Mikael Djurfeldt
fc1d67c47b * unif.c (scm_uniform_vector_ref, scm_cvref, scm_array_set_x,
rapr1): Use SCM_UCHARS instead of SCM_CHARS for strings.  (Thanks
to Ole Myren Röhne.)
1998-04-12 23:36:54 +00:00
Mikael Djurfeldt
360fc44c98 * ports.c (scm_port_line, scm_set_port_line_x, scm_port_column,
scm_set_port_column_x, scm_port_filename,
scm_set_port_filename_x): Removed optional arguments.  Added
proper argument checking.
1998-04-12 23:35:17 +00:00
Mikael Djurfeldt
a74145b809 * eval.c, eval.h, coop.c (scm_eval_stack, SCM_EVAL_STACK): Measure
stack size in machine words.
1998-04-12 23:34:43 +00:00
Mikael Djurfeldt
1ba8c23aca * socket.c: Check for HAVE_UNIX_DOMAIN_SOCKETS instead of
UNIX_DOMAIN_SOCKETS.  (Thanks to Lauri Alanko.)
1998-04-12 16:27:48 +00:00
Mikael Djurfeldt
6f3067f1e0 * gc.c (scm_gc_sweep): Count cells correctly. (Thanks to Ben
Caradoc-Davies.)
1998-04-12 10:23:20 +00:00
Mikael Djurfeldt
1609038c87 * eval.c (SCM_CEVAL, SCM_APPLY): In SCM_IM_APPLY and in the
procedure apply: Copy argument lists before pushing them unto the
environment so that the environment won't get mutated due to
manipulation of procedure arguments.  This should perhaps be
regarded as a temporary solution until someone finds a more
efficient one.  (Thanks to Maciej Stachowiak.)
1998-04-12 10:10:29 +00:00
Mark Galassi
17bf105df1 trivial 1998-04-11 12:40:19 +00:00
Mikael Djurfeldt
5798fd9790 New libtool: 1.2
* ltconfig, ltmain.sh, config.sub, config.guess: Updated.
New automake: 1.3
* Makefile.in, aclocal.m4, configure: Regenerated.
* README: Mention new version numbers on libtool and automake.
1998-04-11 09:51:40 +00:00
Mikael Djurfeldt
1abb11b658 * script.c (scm_compile_shell_switches): Use "guile" as default
zero arg if argc is NULL.
1998-04-10 19:01:53 +00:00
Mikael Djurfeldt
d0e32dd50d * script.c (scm_compile_shell_switches): Allow NULL argv if argc
is zero.  (Thanks to Dirk Herrmann.)
1998-04-02 09:25:00 +00:00
Mikael Djurfeldt
ac67270dcf *** empty log message *** 1998-03-30 21:04:09 +00:00
Mikael Djurfeldt
cda139a791 * gsubr.c (scm_gsubr_apply): Added dummy return to avoid compiler
warning.

* eval.c, numbers.c, unif.c, srcprop.c: Added a few curly braces
to avoid compiler warnings.

* dynl-dl.c (sysdep_dynl_func): Only define usymb if needed.
1998-03-30 21:03:35 +00:00
Mikael Djurfeldt
33b974026b * eval.h, eval.c, debug.h, debug.c (scm_evaluator_traps): Moved
from debug.c --> eval.c

* eval.h, eval.c (scm_eval_options_interface): New options
interface.
(SCM_EVAL_STACK): New option: Size of newly created stacks,
i.e. stacks for new threads.

* eval.c (unsafe_setjmp): Removed with #if 0.

* eval.c, numbers.c, unif.c, srcprop.c: Added a few curly braces
to avoid compiler warnings.
1998-03-30 21:02:59 +00:00
Mikael Djurfeldt
51d394a1c5 * coop.c (COOP_STKSIZE): Use SCM_EVAL_STACK. 1998-03-30 21:02:31 +00:00
Mikael Djurfeldt
0e929db3d1 * ports.c (scm_add_to_port_table): First line is now line 0
(was 1).  (Interface changed according to suggestion by Per
Bothner.)

* backtrace.c (display_header): Add 1 to line and column numbers
when presenting them to the user.
1998-03-30 19:31:52 +00:00
Mikael Djurfeldt
d0defdf3aa * ports.c (scm_add_to_port_table): First line is now line 0
(was 1).  (Interface changed according to suggestion by Per
Bothner.)

* backtrace.c (display_header): Add 1 to line and column numbers
when presenting them to the user.
1998-03-30 19:22:16 +00:00
Mikael Djurfeldt
701191ba9c * throw.c (handler_message): Print message on current error port
instead of default error port.  (Thanks to Maciej Stachowiak.)
1998-03-28 20:26:17 +00:00
Gary Houston
67fe060ed5 * ports.c (scm_add_to_port_table): allocate in units of
struct scm_port_table *, not struct scm_port_table.
	* posix.c (scm_close_pipe): remove the port from the port table
	and mark as closed.
	Thanks to Rob Engle for both fixes.
1998-03-03 10:11:13 +00:00
Mark Galassi
186d31e78c minor: remove some commented out old code 1998-03-01 07:25:59 +00:00
Mikael Djurfeldt
d90ca38d06 * iselect.h, iselect.c, coop.c, coop-threads.c, coop-threads.h,
coop-defs.h, throw.c, backtrace.c: Added new copyright year 1998.
1998-02-06 18:55:29 +00:00
Mikael Djurfeldt
492960a4f4 * throw.h: Removed jmpbuf arg in scm_catch_body_t.
* backtrace.c (display_error_body, display_backtrace_body),
coop-threads.c (scheme_body_bootstrip, c_body_bootstrip),
gh_eval.c (eval_str_wrapper, eval_file_wrapper), init.c
(invoke_main_func), root.c (cwdr_body), throw.c (cwss_body,
scm_body_thunk, hbpca_body): Removed the second jmpbuf arg on body
functions.

* throw.c (scm_internal_catch, scm_internal_lazy_catch): Bodies
don't receive the jmpbuf arg anylonger.
(scm_catch): Don't accept a #f tag.
(scm_throw): Check that key is a symbol.
(scm_ithrow): Don't take a jmpbuf as key.  Don't check key arg.
1998-02-02 15:00:59 +00:00
Mikael Djurfeldt
39752bec0a * backtrace.c (display_error_body, display_backtrace_body),
coop-threads.c (scheme_body_bootstrip, c_body_bootstrip),
gh_eval.c (eval_str_wrapper, eval_file_wrapper), init.c
(invoke_main_func), root.c (cwdr_body), throw.c (cwss_body,
scm_body_thunk, hbpca_body): Removed the second jmpbuf arg on body
functions.
1998-02-02 15:00:14 +00:00