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

4517 commits

Author SHA1 Message Date
Rob Browning
8048c00b4f *** empty log message *** 2004-06-16 04:10:37 +00:00
Rob Browning
537abaae4d update ifdefery for macosx.
(scm_get_stack_base): separate result initialization from
declaration to slience warnings with macosx and hp-ux using gcc
3.3.  Thanks to Andreas Vögele.
2004-06-16 04:09:52 +00:00
Rob Browning
17c22047f8 (scm_shell_usage): minor phrasing change. 2004-06-16 04:08:25 +00:00
Han-Wen Nienhuys
d93294d451 (unmemoize_exprs): use SCM_CONSP for the loop condition. 2004-06-12 22:22:56 +00:00
Dirk Herrmann
212e58ede8 * list.[ch] (scm_i_finite_list_copy): New internal function to
copy lists that are known to be finite (though not necessarily
	proper).

	* debug.c (scm_procedure_source): Don't have scm_unmemocopy treat
	a closure's argument list like an expression of a body.

	* eval.c (unmemoize_expression, unmemoize_exprs, unmemoize_and,
	unmemoize_begin, unmemoize_case, unmemoize_cond, unmemoize_delay,
	unmemoize_do, unmemoize_if, unmemoize_lambda, unmemoize_let,
	unmemoize_letrec, unmemoize_letstar, unmemoize_or,
	unmemoize_set_x, unmemoize_apply, unmemoize_atcall_cc,
	unmemoize_at_call_with_values, unmemoize_future, sym_atslot_ref,
	unmemoize_atslot_ref, sym_atslot_set_x, unmemoize_atslot_set_x,
	unmemoize_builtin_macro): New static functions and symbols.

	(scm_unmemocopy): Rewritten in terms of the above.  scm_unmemocopy
	now has a slightly different meaning: The memoized form that is
	receives as its argument is now interpreted as a sequence of
	expressions from a body.

	(unmemocar, scm_unmemocar): Since the whole functionality of
	unmemocar and scm_unmemocar is not needed any more, scm_unmemocar
	has its old content back and is deprecated, while unmemocar has
	been removed.

	(SCM_BIT7): Removed.

	(CEVAL): For unmemoizing a single expression, call
	unmemoize_expression instead of scm_unmemocopy, which now expects
	a sequence of body expressions.  Eliminated unnecessary empty
	environment frame when executing let* forms.  Eliminated
	unmemoization step from evaluator.
2004-06-06 07:46:18 +00:00
Marius Vollmer
9ccea37043 *** empty log message *** 2004-06-02 09:44:55 +00:00
Marius Vollmer
2b189e65c4 (scm_macroexp, macroexp): Renamed scm_macroexp to
macroexp and made static.  Added new version of scm_macroexp that
emits a deprecation warning and then calls macroexp.
(scm_m_undefine): Issue deprecation warning.
2004-06-02 09:37:48 +00:00
Dirk Herrmann
57d23e259a * eval.c (lookup_global_symbol, literal_p, try_macro_lookup):
Modified to make set! work on symbols that represent syntactic
	keywords.
2004-05-30 07:01:27 +00:00
Han-Wen Nienhuys
141521ad8b (SCM_CELL_OBJECT_LOC): use SCM_GC_CELL_OBJECT to prevent
compound expression as lvalue errors.
2004-05-26 21:15:30 +00:00
Marius Vollmer
7c2f56a4de *** empty log message *** 2004-05-24 21:29:26 +00:00
Marius Vollmer
78addfa35e (winder_mark): Use SCM_PACK to correctly convert the WINDER_DATA to a
SCM.
2004-05-24 21:14:59 +00:00
Dirk Herrmann
366ecaec7a * goops.c (compute_getters_n_setters, create_standard_classes,
scm_add_slot): Compute closures by calling scm_i_eval_x on a
	lambda expression rather than creating them with scm_closure.
2004-05-24 04:15:49 +00:00
Dirk Herrmann
26ecfa393d * eval.c (s_macro_keyword, scm_m_set_x): Remove checking for
misplaced syntactic keywords.  This will not work unless guile's
	defmacro feature is deprecated.

	(scm_m_case): Fixed a bug that caused the list of labels to grow
	with every case form.
2004-05-22 06:51:36 +00:00
Kevin Ryde
f865229a61 *** empty log message *** 2004-05-19 00:06:42 +00:00
Kevin Ryde
659998043d (scm_threads_mark_stacks) [SCM_STACK_GROWS_UP]: Correction
to stack marking call, two parameters and no cast on t->base.
2004-05-19 00:04:16 +00:00
Kevin Ryde
faff1f2fda (trunc): Remove #define to scm_truncate when the C library
doesn't provide trunc.  This was for when `truncate' was done as a
scm_tc7_dsubr, no longer required.
2004-05-18 23:45:34 +00:00
Kevin Ryde
bae30667b0 (scm_round_number): For inum and big, just return x. For
real, use scm_round for 2^54-1 etc problems covered there.
2004-05-18 23:43:28 +00:00
Marius Vollmer
63947c7ad3 *** empty log message *** 2004-05-18 21:55:11 +00:00
Marius Vollmer
e0245b20cb (rehash_after_gc): Bug fix: properly link the processed hashtables
back into the weak_hashtables list.  Thanks to Bill Schottstaedt!
2004-05-18 21:29:38 +00:00
Dirk Herrmann
e7313a9d7e * eval.c (unmemoize_quote): New static function.
(scm_m_quote, scm_m_atslot_ref, SCM_CEVAL): Changed the byte code
	representation of 'quote' and '@slot-ref' to an improper list.
	This reduces execution time, the number of cells used to hold the
	memoized code, and thus also reduces garbage collection time.

	(scm_unmemocopy): Use unmemoize_quote for quote expressions.

	(SCM_CEVAL): Changed macro handling to also work with macros that
	return improper lists.  Added an assertion, that the code returned
	by a macro transformer will not lead to cycles in the memoized
	code.
2004-05-16 06:38:51 +00:00
Dirk Herrmann
e51565673c No functional change, just rearrangements of functions within the
file.

	* eval.c (scm_ilookup, scm_unbound_variable_key,
	error_unbound_variable, scm_lookupcar1, scm_lookupcar): Moved to
	the definitions used for execution, since that's where they will
	belong to later.
2004-05-15 16:45:27 +00:00
Dirk Herrmann
651f07f82e * numbers.h (SCM_SLOPPY_FRACTIONP): Removed. It was not used
throughout guile, has not been part of an official release yet,
	and the concept of sloppy predicates has never been a good idea.

	(SCM_FRACTION_NUMERATOR, SCM_FRACTION_DENOMINATOR,
	SCM_FRACTION_SET_NUMERATOR, SCM_FRACTION_SET_DENOMINATOR):
	Simplified.
2004-05-15 15:50:24 +00:00
Dirk Herrmann
770e048f7d * throw.c (SETJBJMPBUF, SCM_SETJBDFRAME): Add cast to scm_t_bits
to make explicit what happens.
2004-05-15 15:42:47 +00:00
Dirk Herrmann
2ff0840571 * dynl.c (SET_DYNL_HANDLE): Add cast to scm_t_bits to make
explicit what happens.

	* guardians.c (TCONC_IN): Use SCM_SET_CELL_OBJECT_x rather than
	SCM_SET_CELL_WORD_x when writing scheme objets to cell elements.
2004-05-15 15:39:27 +00:00
Marius Vollmer
89afb9cd52 *** empty log message *** 2004-05-10 22:10:02 +00:00
Marius Vollmer
43067cec3b (scm_sigaction_for_thread): Validate that the handler is indeed a
procedure when it isn't a number.
2004-05-10 22:09:04 +00:00
Marius Vollmer
3d5ebfa95c *** empty log message *** 2004-05-10 20:43:00 +00:00
Marius Vollmer
0b799eeab6 (FLOBUFLEN): Increase so that radix 2 strings will fit.
(fx): Removed.
(scm_dblprec, fx_per_radix, init_dblprec, init_fx_radix,
number_chars): New, to support variable radices.
(idbl2str): Use above instead of the old base-10 only tables.
(iflo2str): Pass on new RADIX argument to idbl2str.
(scm_number_to_string): Pass radix to iflo2str.
(scm_print_real, scm_print_complex): Explicitly pass radix 10 to
iflo2str.
(scm_init_numbers): Call init_dblprec and init_fx_radix for all
possible radices.
2004-05-10 20:35:39 +00:00
Kevin Ryde
20fcc8ed86 More of:
(scm_logbit_p): Correction to test above the end of an
inum.  Reported by Jan Konecny.
2004-05-09 22:46:17 +00:00
Kevin Ryde
3ae69bb422 *** empty log message *** 2004-05-09 22:34:48 +00:00
Kevin Ryde
0d75f6d819 (scm_logbit_p): Correction to test above the end of an
inum.  Reported by Jan Konecny.
2004-05-09 22:33:29 +00:00
Marius Vollmer
279688252e *** empty log message *** 2004-05-06 16:43:46 +00:00
Marius Vollmer
f5710d53b1 Use SCM_SMOB_* instead of SCM_CELL_* as appropriate. Use
SCM_SMOB_FLAGS and SCM_SET_SMOB_FLAGS instead of accessing the
zeroth word directly.  Use SCM_SMOB_PREDICATE as appropriate.
2004-05-06 16:43:14 +00:00
Marius Vollmer
41a2f6fc0c (SCM_CELL_WORD_LOC): Moved to "deprecated.h". 2004-05-06 16:42:50 +00:00
Marius Vollmer
fba8fdc0d3 (SCM_I_BIG_MPZ): Use SCM_CELL_OBJECT_LOC instead of taking the address
of SCM_CELL_WORD_1, the latter being no longer an lvalue.
2004-05-06 16:42:07 +00:00
Marius Vollmer
f7e69e2094 (SCM_VARIABLE_LOC): Use SCM_CELL_OBJECT_LOC instead of casting
SCM_CELL_WORD_LOC.
2004-05-06 16:41:47 +00:00
Marius Vollmer
37fc18ae73 * smob.h (SCM_SMOB_DATA_2, SCM_SMOB_DATA_3, SCM_SMOB_FLAGS,
SCM_SET_SMOB_DATA_2, SCM_SET_SMOB_DATA_3, SCM_SET_SMOB_FLAGS,
SCM_SMOB_OBJECT, SCM_SMOB_OBJECT_2, SCM_SMOB_OBJECT_3,
SCM_SET_SMOB_OBJECT, SCM_SET_SMOB_OBJECT_2, SCM_SET_SMOB_OBJECT_3,
SCM_SMOB_OBJECT_LOC, SCM_SMOB_OBJECT_2_LOC,
SCM_SMOB_OBJECT_3_LOC): New.
* smob.c (scm_i_set_smob_flags): New function.
2004-05-06 16:41:27 +00:00
Marius Vollmer
33c527ec83 (scm_t_cell): Fields are now of type SCM instead of
scm_t_bits.  Updated all users.
(SCM_GC_CARD_SIZE_MASK): Use SCM_GC_SIZEOF_CARD instead of
duplicating the code.
(SCM_CELL_OBJECT_LOC): New.
(SCM_CARLOC, SCM_CDRLOC): Use it instead of SCM_CELL_WORD_LOC.
(SCM_CELL_WORD_LOC): Moved to "deprecated.h".
2004-05-06 16:41:08 +00:00
Marius Vollmer
050fedc4fd Fixed typo in comment. 2004-05-06 16:28:18 +00:00
Kevin Ryde
3702692567 *** empty log message *** 2004-05-01 21:51:03 +00:00
Kevin Ryde
0a9ea92c90 (scm_macroexp): Add prototype, since it's not in eval.h under
--disable-deprecated.  Reported by Andreas Vögele.
2004-05-01 21:49:44 +00:00
Kevin Ryde
c585459825 *** empty log message *** 2004-05-01 21:33:12 +00:00
Kevin Ryde
0dbfb25a64 (varargs.h): Remove, leave just stdarg.h which is all the
code has support for.  Fixes building with AIX cc, which is ansi but
doesn't define __STDC__.  Reported by Keith Crane.
(var_start): Remove macro, this variation no longer required.
(scm_list_n): Use va_start directly.
2004-05-01 21:32:03 +00:00
Kevin Ryde
00fbf1e047 More of:
(_POSIX_C_SOURCE): Define to 199506L to get readdir_r (in
particular on HP-UX).  Reported by Andreas Vögele.
2004-05-01 21:30:37 +00:00
Kevin Ryde
3cf17ef002 *** empty log message *** 2004-05-01 21:01:47 +00:00
Kevin Ryde
6d484a0be7 (_POSIX_C_SOURCE): Define to 199506L to get readdir_r (in
particular on HP-UX).  Reported by Andreas Vögele.
2004-05-01 21:00:41 +00:00
Kevin Ryde
f26c1a32ad *** empty log message *** 2004-04-30 23:45:25 +00:00
Kevin Ryde
5afcf08bb2 (scm_dynthrow): Use >= instead of SCM_PTR_GE which
is now gone.  Reported by Andreas Vögele.
2004-04-30 23:34:01 +00:00
Kevin Ryde
a0d06a004f *** empty log message *** 2004-04-28 00:17:45 +00:00
Kevin Ryde
dc30aad370 (scm_threads_mark_stacks): Correction sizet -> size_t.
Reported by Andreas Vögele.
2004-04-28 00:15:54 +00:00