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

741 commits

Author SHA1 Message Date
Marius Vollmer
b0d10ba69f Tidied up somewhat. 2004-08-25 17:22:14 +00:00
Marius Vollmer
c5080b5189 *** empty log message *** 2004-08-24 22:25:02 +00:00
Marius Vollmer
3ece39d651 *** empty log message *** 2004-08-22 19:31:32 +00:00
Marius Vollmer
3ff9283dd6 *** empty log message *** 2004-08-19 17:54:37 +00:00
Marius Vollmer
c41acab35c *** empty log message *** 2004-08-12 17:52:49 +00:00
Marius Vollmer
409eb4e54f *** empty log message *** 2004-08-09 23:33:27 +00:00
Marius Vollmer
96d8c21757 *** empty log message *** 2004-08-03 17:16:29 +00:00
Marius Vollmer
f9656a9f82 *** empty log message *** 2004-08-03 15:56:49 +00:00
Marius Vollmer
f7f3964e89 *** empty log message *** 2004-08-02 16:26:50 +00:00
Marius Vollmer
d5b203a684 *** empty log message *** 2004-07-23 15:51:33 +00:00
Marius Vollmer
ae7ded5671 *** empty log message *** 2004-06-28 13:40:18 +00:00
Dirk Herrmann
9fcf3cbb81 * backtrace.c (display_expression, display_frame): Call
scm_i_unmemoize_expr for unmemoizing a memoized object holding a
	single memoized expression.

	* debug.c (memoized_print): Don't try to unmemoize the memoized
	object, since we can't know whether it holds a single expression
	or a body.

	(scm_mem_to_proc): Removed check for lambda expression, since it
	was moot anyway.  Whoever uses these functions for debugging
	purposes should know what they do: Creating invalid memoized code
	will cause crashes, independent of whether this check is present
	or not.

	(scm_proc_to_mem): Take the closure's code as it is and don't
	append a SCM_IM_LAMBDA isym.  To allow easier debugging, the
	memoized code should not be modified.

	* debug.[ch] (scm_unmemoize, scm_i_unmemoize_expr): Removed
	scm_unmemoize from public use, but made scm_i_unmemoize_expr
	available as a guile internal function instead.  However,
	scm_i_unmemoize_expr will only work on memoized objects that hold
	a single memoized expression.  It won't work with bodies.

	* debug.c (scm_procedure_source), macros.c (macro_print), print.c
	(scm_iprin1): Call scm_i_unmemocopy_body for unmemoizing a body,
	i. e. a list of expressions.

	* eval.c (unmemoize_exprs): Drop internal body markers from the
	output during unmemoization.

	* eval.[ch] (scm_unmemocopy, scm_i_unmemocopy_expr,
	scm_i_unmemocopy_body): Removed scm_unmemocopy from public use,
	but made scm_i_unmemocopy_expr and scm_i_unmemocopy_body available
	as guile internal functions instead.  scm_i_unmemoize_expr will
	only work on a single memoized expression, while
	scm_i_unmemocopy_body will only work on bodies.
2004-06-27 12:34:54 +00:00
Rob Browning
f5d54eb740 *** empty log message *** 2004-06-20 17:24:42 +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
c1e7caf726 *** empty log message *** 2004-05-06 17:04:04 +00:00
Marius Vollmer
279688252e *** empty log message *** 2004-05-06 16:43:46 +00:00
Dirk Herrmann
7e6e6b37ba Hide the implementation of ilocs and isyms in eval.c.
* deprecated.h (SCM_IFRINC, SCM_ICDR, SCM_IFRAME, SCM_IDIST,
	SCM_ICDRP), eval.c (SCM_IFRINC, SCM_ICDR, SCM_IFRAME, SCM_IDIST,
	SCM_ICDRP), eval.h (SCM_ICDR, SCM_IFRINC, SCM_IFRAME, SCM_IDIST,
	SCM_ICDRP): Deprecated and added to deprecated.h.  Moved from
	eval.h to eval.c.

	* deprecated.c (scm_isymnames), deprecated.h (scm_isymnames,
	SCM_ISYMNUM, SCM_ISYMCHARS), eval.c (SCM_ISYMNUM, isymnames,
	scm_unmemocopy, CEVAL), print.c (scm_isymnames), tags.h
	(SCM_ISYMNUM, scm_isymnames, SCM_ISYMCHARS): Deprecated
	scm_isymnames, SCM_ISYMNUM and SCM_ISYMCHARS and added to
	deprecated.[hc].  Moved scm_isymnames from print.c to eval.c and
	renamed to isymnames.  Moved SCM_ISYMNUM from tags.h to eval.c and
	renamed to ISYMNUM.

	* eval.c (scm_i_print_iloc, scm_i_print_isym), eval.h
	(scm_i_print_iloc, scm_i_print_isym), print.c (scm_iprin1):
	Extracted printing of ilocs and isyms to guile internal functions
	scm_i_print_iloc, scm_i_print_isym of eval.c.
2004-04-22 19:19:17 +00:00
Dirk Herrmann
5065b40d60 * tags.h (scm_tags, scm_tc8_tags, scm_tc9_flag, scm_tc8_flag,
scm_tc8_isym): Renamed scm_tags to scm_tc8_tags.  Renamed
	scm_tc9_flag to scm_tc8_flag.  Introduced new identifier
	scm_tc8_isym.  Defined tc8-tags relative to scm_tc3_imm24.
	Defined the tc8-tag for flags to be 0x04, which will mean that
	SCM_BOOL_F will also have the value 0x04 instead of 0x013c.  Due
	to the reduced number of bits and the simpler bit pattern for
	SCM_BOOL_F, certain machines may be able to use more efficient
	processor instructions to deal with SCM_BOOL_F.

	(SCM_ITAG9, SCM_MAKE_ITAG9, SCM_ITAG9_DATA): Removed.  These have
	never been defined in a released version, thus no need to
	deprecate them.

	(SCM_IFLAGP, SCM_MAKIFLAG, SCM_IFLAGNUM): Flags now use tc8
	instead of tc9 tags.

	(SCM_ISYMP, SCM_MAKISYM, SCM_ISYMNUM): Isyms now use tc8 instead
	of tc9 tags.

	(SCM_MAKSPCSYM): Removed.  It is almost impossible that user code
	could have used this definition.

	(SCM_IM_AND, SCM_IM_BEGIN, SCM_IM_CASE, SCM_IM_COND, SCM_IM_DO,
	SCM_IM_IF, SCM_IM_LAMBDA, SCM_IM_LET, SCM_IM_LETSTAR,
	SCM_IM_LETREC, SCM_IM_OR, SCM_IM_QUOTE, SCM_IM_SET_X): Now encoded
	as isyms, as special isyms don't exist any more.
2004-04-18 08:56:27 +00:00
Dirk Herrmann
434f2f7a91 Introduce scm_debug_mode_p as a replacement for scm_debug_mode and
SCM_DEBUGGINGP:

	* debug.h (scm_debug_mode_p, scm_debug_mode, SCM_DEBUGGINGP),
	eval.c (scm_debug_mode_p): Deprecated scm_debug_mode and
	SCM_DEBUGGINGP.  Provided scm_debug_mode_p instead, to have one
	single interface that also matches the naming conventions.
	Probably scm_debug_mode_p should be part of the private interface
	anyway.

	* debug.h (scm_debug_mode_p), backtrace.c (display_error_body),
	eval.c (SCM_APPLY, scm_trampoline_0, scm_trampoline_1,
	scm_trampoline_2): Change uses of scm_debug_mode or SCM_DEBUGGINGP
	to scm_debug_mode_p.


	Deprecate direct access to scm_ceval, scm_deval and scm_ceval_ptr:

	* eval.h (scm_ceval, scm_deval, scm_ceval_ptr), debug.h
	(scm_ceval_ptr): Deprecated.  Moved declaration of scm_ceval_ptr
	from debug.h to eval.h.

	* debug.h (SCM_RESET_DEBUG_MODE): Don't access scm_ceval_ptr any
	more, just leave it with setting scm_debug_mode_p, which is
	equivalent for practical purposes.

	* deprecated.h (SCM_XEVAL, SCM_XEVALCAR): Call scm_i_eval_x
	instead of *scm_ceval_ptr.  Leave all evaluating to scm_i_eval_x.

	* gdbint.c (gdb_eval): Call scm_i_eval_x instead of scm_ceval.

	* eval.c (ceval, deval, scm_ceval, scm_deval): Made scm_ceval
	static and renamed it to ceval throughout.  Provide a new exported
	but deprecated function scm_ceval as a wrapper for backwards
	compatibility.  The same is done for the deval/scm_deval pair of
	functions.

	* eval.c (CEVAL, SCM_CEVAL): Renamed SCM_CEVAL to CEVAL
	throughout.  Defined CEVAL to ceval or deval, based on compilation
	phase.

	* eval.c (SCM_XEVAL, SCM_XEVALCAR): Dispatch on scm_debug_mode_p
	to ceval and deval instead of calling *scm_ceval_ptr.

	* eval.c (dispatching_eval): New deprecated static function.

	* eval.c (scm_ceval_ptr): Initialized to dispatching_eval in order
	to emulate its old behaviour as closely as possible.


	Change the evaluator such that only expressions for which pair? is
	true are passed to CEVAL, and such that all other expressions are
	evaluated outside of CEVAL:

	* eval.c (EVAL): New, provided in analogy to EVALCAR.  Evaluate an
	expression that is assumed to be memoized already.  All but
	expressions of the form '(<form> <form> ...)' are evaluated inline
	without calling an evaluator.

	* eval.c (SCM_XEVAL, SCM_XEVALCAR, EVALCAR): Evaluate all but
	expressions of the form '(<form> <form> ...)' inline without
	calling an evaluator.

	* eval.c (scm_i_eval_x, scm_i_eval, scm_ceval, scm_deval): Handle
	the special case of unmemoized symbols passed on the top level.

	* eval.c (CEVAL): Change calls to CEVAL to EVAL, except where it
	is known that the expression passed to CEVAL is of the form
	'(<form> <form> ...)'.  Remove handling of the tc7-objects, since
	now it is known that the input expression of CEVAL is a pair.
2004-03-29 19:59:43 +00:00
Kevin Ryde
71f271b2bb Refer to manual for details of new pretty-print options. 2004-02-12 00:33:58 +00:00
Marius Vollmer
77e51fd6ed *** empty log message *** 2004-01-22 23:28:27 +00:00
Marius Vollmer
9a5fc8c203 *** empty log message *** 2004-01-21 00:47:50 +00:00
Marius Vollmer
f1da8e4e0b Renamed scm_frame_unwind to scm_frame_unwind_handler, and
scm_frame_rewind to scm_frame_rewind_handler.
2004-01-11 00:56:05 +00:00
Marius Vollmer
fc6bb2831d *** empty log message *** 2004-01-07 18:18:09 +00:00
Marius Vollmer
49c00ecc7b *** empty log message *** 2004-01-04 23:45:38 +00:00
Marius Vollmer
9879d3906e Added section about frames. 2004-01-03 21:57:11 +00:00
Marius Vollmer
89fcf1b4aa *** empty log message *** 2003-12-26 19:09:03 +00:00
Marius Vollmer
fb16d26e23 *** empty log message *** 2003-11-19 05:13:53 +00:00
Marius Vollmer
bdf26b606b *** empty log message *** 2003-11-18 20:01:57 +00:00
Rob Browning
5a76d4dc05 *** empty log message *** 2003-11-17 18:59:08 +00:00
Marius Vollmer
aff7e166e8 *** empty log message *** 2003-11-17 00:38:25 +00:00
Dirk Herrmann
6f81708ae0 * eval.c (s_splicing): Commented and reformulated.
(lookup_global_symbol, lookup_symbol): New static functions.

	(s_test, s_bindings, s_duplicate_bindings, s_variable): Removed.

	(try_macro_lookup, literal_p): Use lookup_symbol instead of
	creating a temporary pair for scm_lookupcar.

	(scm_unmemocar, unmemocar): Renamed scm_unmemocar to unmemocar,
	created deprecated wrapper function scm_unmemocar.

	(SCM_VALIDATE_NON_EMPTY_COMBINATION, scm_sym_else,
	scm_sym_unquote, scm_sym_uq_splicing, scm_sym_enter_frame,
	scm_sym_apply_frame, scm_sym_exit_frame, scm_sym_trace, f_apply,
	undefineds, sym_three_question_marks): Moved around without
	modifications.

	* eval.c, eval.h (scm_macroexp, scm_unmemocar): Deprecated.
2003-11-16 10:47:45 +00:00
Dirk Herrmann
328dc9a3ef * eval.c, eval.h (scm_m_expand_body, m_expand_body): Deprecated
public use of scm_m_expand_body in eval.h.  In eval.c, renamed
	scm_m_expand_body to m_expand_body and made it static.  Added
	deprecated wrapper scm_m_expand_body.

	(scm_eval_body, SCM_CEVAL, SCM_APPLY): Use m_expand_body instead
	of scm_m_expand_body.
2003-11-09 08:10:58 +00:00
Kevin Ryde
88fd89ac40 Add call-with-output-string no segv on closed port. 2003-10-01 23:51:41 +00:00
Dirk Herrmann
f03314f920 * numbers.h (SCM_INEXACTP): Removed uses of SCM_TYP16S.
* tags.h, deprecated.h (SCM_TYP16S): Deprecated and moved from
	tags.h to deprecated.h.
2003-09-21 07:54:23 +00:00
Kevin Ryde
69fc37da29 Add ice-9 popen duplicate pipe fd fix. 2003-09-19 01:30:54 +00:00
Dirk Herrmann
0d5e348022 * numbers.h (SCM_INEXACTP, SCM_REALP, SCM_COMPLEXP): Removed uses
of SCM_SLOPPY_INEXACTP, SCM_SLOPPY_REALP and SCM_SLOPPY_COMPLEXP.

	* numbers.h, deprecated.h (SCM_SLOPPY_INEXACTP, SCM_SLOPPY_REALP,
	SCM_SLOPPY_COMPLEXP): Deprecated and moved from numbers.h to
	deprecated.h.
2003-09-06 09:17:29 +00:00
Kevin Ryde
36a9b2364c Add srfi-19 date-week-number fix. 2003-08-22 23:32:55 +00:00
Kevin Ryde
1363e3e71f Add new "while" proper break and continue.
Add srfi-1 list-copy of improper lists.
2003-08-22 23:17:50 +00:00
Kevin Ryde
ba6a6d5535 Add source-properties versus set-source-properties! fix. 2003-08-08 23:28:11 +00:00
Kevin Ryde
382053e987 Shrink new parallel forms stuff, now described in the manual. 2003-07-24 00:14:59 +00:00
Kevin Ryde
83dbedccdb Shrink scm_call_X, scm_apply_X and scm_list_X entries, now described
in the manual.
2003-07-18 01:28:38 +00:00
Marius Vollmer
983e697d52 *** empty log message *** 2003-06-29 14:57:54 +00:00
Marius Vollmer
66c8ded2a5 Removed the re-added deprecated symbols. 2003-06-19 12:40:50 +00:00
Marius Vollmer
8d54e73a89 Updated NEWS entry about threading. 2003-06-09 20:17:35 +00:00
Kevin Ryde
18f7ef3859 Shrink the futures entry, details now in the manual. 2003-06-04 16:46:02 +00:00
Dirk Herrmann
d0624e391b * __scm.h, gc-card.c (SCM_DEBUG_DEBUGGER_SUPPORT,
SCM_DEBUG_DEBUGGING_SUPPORT): Renamed macro
	SCM_DEBUG_DEBUGGER_SUPPORT to SCM_DEBUG_DEBUGGING_SUPPORT and
	generalized it to apply not only to C level functions but also to
	scheme level functions.

	* debug.c, debug.h, eval.c (make-iloc, scm_make_iloc, iloc?,
	scm_iloc_p, dbg-make-iloc, scm_dbg_make_iloc, dbg-iloc?,
	scm_dbg_iloc_p): Moved functions scm_make_iloc, scm_iloc_p to
	eval.c, made them available under SCM_DEBUG_DEBUGGING_SUPPORT == 1
	only and renamed them to scm_dbg_make_iloc, scm_dbg_iloc_p,
	respectively.

	* deprecated.h, eval.c, eval.h (SCM_ILOC00, SCM_IDINC,
	SCM_IDSTMSK): Deprecated.  The macro definitions are moved from
	eval.h into eval.c and a copy is placed into deprecated.h.

	* eval.c, eval.h (SCM_MAKE_ILOC): Removed from eval.h and placed
	into eval.c. This definition was not part of the API in any
	officially released version of guile and thus does not need to go
	through a phase of deprecation.
2003-06-04 05:28:34 +00:00
Dirk Herrmann
e90c3a895d * deprecated.c, deprecated.h, eval.c, eval.h: Deprecated
scm_s_expression, scm_s_test, scm_s_body, scm_s_bindings,
	scm_s_variable, scm_s_clauses, scm_s_formals.  In eval.c the
	definitions are make static and renamed from scm_s_xxx to s_xxx.
	In deprecated.c the original definitions are copied.

	* deprecated.h, eval.c, eval: Deprecated SCM_EVALIM2, SCM_EVALIM,
	SCM_XEVAL and SCM_XEVALCAR.  The macro definitions are moved from
	eval.h into eval.c and a copy (slightly modified to work in user
	code) is placed into deprecated.h.

	* eval.c: Use the local static s_xxx definitions instead of the
	scm_s_xxx definitions throughout.
2003-06-02 20:54:21 +00:00
Marius Vollmer
8549458751 *** empty log message *** 2003-05-20 19:59:52 +00:00
Marius Vollmer
47dee22897 *** empty log message *** 2003-05-20 19:14:38 +00:00