diff options
author | Mikael Djurfeldt <djurfeldt@nada.kth.se> | 1996-09-22 22:41:10 +0000 |
---|---|---|
committer | Mikael Djurfeldt <djurfeldt@nada.kth.se> | 1996-09-22 22:41:10 +0000 |
commit | 19402679360bfd4d2cd1b87d78bbc5687d03f92b (patch) | |
tree | 1bef6dfdc7f76e2e3ec430810be7c3bcf5f13722 /libguile/eval.c | |
parent | 2c36c351d0b9598a6a89218b983614257387ae11 (diff) | |
download | guile-19402679360bfd4d2cd1b87d78bbc5687d03f92b.tar.gz |
* eval.c, numbers.h, unif.h, smob.h, srcprop.c: Added #include
"print.h"
* arbiters.c (prinarb),
async.c (print_async),
debug.c (prindebugobj, prinmemoized),
eval.c (prinprom, prinmacro),
filesys.c (scm_fd_print, scm_dir_print),
kw.c (print_kw),
mallocs.c (prinmalloc),
numbers.c, numbers.h (scm_floprint, scm_bigprint),
smob.h (scm_smobfuns),
srcprop.c (prinsrcprops),
throw.c (prinjb),
unif.c, unif.h (scm_raprin1, rapr1),
variable.c (prin_var): Changed argument `int writing' to
`scm_print_state *pstate'.
Diffstat (limited to 'libguile/eval.c')
-rw-r--r-- | libguile/eval.c | 23 |
1 files changed, 15 insertions, 8 deletions
diff --git a/libguile/eval.c b/libguile/eval.c index 5acfcedfe..898642c3c 100644 --- a/libguile/eval.c +++ b/libguile/eval.c @@ -68,6 +68,7 @@ #include "procprop.h" #include "hashtab.h" #include "hash.h" +#include "print.h" #ifdef DEBUG_EXTENSIONS #include "debug.h" @@ -2772,17 +2773,20 @@ scm_makprom (code) #ifdef __STDC__ static int -prinprom (SCM exp, SCM port, int writing) +prinprom (SCM exp, SCM port, scm_print_state *pstate) #else static int -prinprom (exp, port, writing) +prinprom (exp, port, pstate) SCM exp; SCM port; - int writing; + scm_print_state *pstate; #endif { + int writingp = SCM_WRITINGP (pstate); scm_gen_puts (scm_regular_string, "#<promise ", port); - scm_iprin1 (SCM_CDR (exp), port, writing); + SCM_SET_WRITINGP (pstate, 1); + scm_iprin1 (SCM_CDR (exp), port, pstate); + SCM_SET_WRITINGP (pstate, writingp); scm_gen_putc ('>', port); return !0; } @@ -2844,15 +2848,16 @@ scm_makmmacro (code) #ifdef __STDC__ static int -prinmacro (SCM exp, SCM port, int writing) +prinmacro (SCM exp, SCM port, scm_print_state *pstate) #else static int -prinmacro (exp, port, writing) +prinmacro (exp, port, pstate) SCM exp; SCM port; - int writing; + scm_print_state *pstate; #endif { + int writingp = SCM_WRITINGP (pstate); if (SCM_CAR (exp) & (3L << 16)) scm_gen_puts (scm_regular_string, "#<macro", port); else @@ -2860,7 +2865,9 @@ prinmacro (exp, port, writing) if (SCM_CAR (exp) & (2L << 16)) scm_gen_putc ('!', port); scm_gen_putc (' ', port); - scm_iprin1 (SCM_CDR (exp), port, writing); + SCM_SET_WRITINGP (pstate, 1); + scm_iprin1 (SCM_CDR (exp), port, pstate); + SCM_SET_WRITINGP (pstate, writingp); scm_gen_putc ('>', port); return !0; } |