diff options
author | Jim Blandy <jimb@red-bean.com> | 1998-10-09 10:02:41 +0000 |
---|---|---|
committer | Jim Blandy <jimb@red-bean.com> | 1998-10-09 10:02:41 +0000 |
commit | 0f88a8f3bda336c5c26341f3899ce5aa61d4db3c (patch) | |
tree | 379332b56d1cddc4155e6c2c2566e6702443b534 /libguile/genio.c | |
parent | ea9fc30d4bbe511bc6403d9f0a6a1d1725414ffa (diff) | |
download | guile-0f88a8f3bda336c5c26341f3899ce5aa61d4db3c.tar.gz |
Change the definition of the functions in scm_ptobfuns so that
they get passed the port object, not the port's stream.
* ports.h (scm_ptobfuns): Rename all `stream' arguments to `port'.
* gc.c (scm_gc_sweep): Pass the port itself to the free function.
* genio.c (scm_putc, scm_puts, scm_lfwrite, scm_fflush, scm_getc):
Pass the port itself to the scm_ptobs function.
* ports.c (scm_close_port, scm_force_output, scm_flush_all_ports,
scm_generic_fgets): Same.
(putc_void_port, puts_void_port, write_void_port, flush_void_port,
getc_void_port, fgets_void_port, close_void_port): Just change the
argument names; these functions don't really do anything.
* fports.c (local_fgetc, local_fgets, local_fclose, local_fflush,
local_fputc, local_fputs, local_ffwrite, local_pclose): Take the
port as an argument, and use SCM_STREAM to get the stdio FILE *.
Also, use prototyped definitions, and get rid of the extra
declarations.
(scm_fptob, scm_pipob): We don't need casts here any more.
* strports.c (prinstpt): Use prototype declarations.
(stputc, stwrite, stputs, stgetc): Take the port as an argument,
and use SCM_STREAM to get the string info. Also, use prototyped
definitions, and get rid of the extra declarations.
* vports.c (sfputc, sfwrite, sfputs, sfflush, sfgetc, sfclose,
noop0): Same.
Diffstat (limited to 'libguile/genio.c')
-rw-r--r-- | libguile/genio.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/libguile/genio.c b/libguile/genio.c index 1b04a0ce9..6db2cb574 100644 --- a/libguile/genio.c +++ b/libguile/genio.c @@ -59,7 +59,7 @@ scm_putc (c, port) SCM port; { scm_sizet i = SCM_PTOBNUM (port); - SCM_SYSCALL ((scm_ptobs[i].fputc) (c, SCM_STREAM (port))); + SCM_SYSCALL ((scm_ptobs[i].fputc) (c, port)); } void @@ -68,7 +68,7 @@ scm_puts (s, port) SCM port; { scm_sizet i = SCM_PTOBNUM (port); - SCM_SYSCALL ((scm_ptobs[i].fputs) (s, SCM_STREAM (port))); + SCM_SYSCALL ((scm_ptobs[i].fputs) (s, port)); #ifdef TRANSCRIPT_SUPPORT if (scm_trans && (port == def_outp || port == cur_errp)) SCM_SYSCALL (fputs (s, scm_trans)); @@ -82,7 +82,7 @@ scm_lfwrite (ptr, size, port) SCM port; { scm_sizet i = SCM_PTOBNUM (port); - SCM_SYSCALL (scm_ptobs[i].fwrite(ptr, size, 1, SCM_STREAM (port))); + SCM_SYSCALL (scm_ptobs[i].fwrite (ptr, size, 1, port)); #ifdef TRANSCRIPT_SUPPORT if (scm_trans && (port == def_outp || port == cur_errp)) SCM_SYSCALL (fwrite (ptr, size, 1, scm_trans)); @@ -95,7 +95,7 @@ scm_fflush (port) SCM port; { scm_sizet i = SCM_PTOBNUM (port); - (scm_ptobs[i].fflush) (SCM_STREAM (port)); + (scm_ptobs[i].fflush) (port); } @@ -133,7 +133,7 @@ scm_getc (port) while (n == -1 && errno == EINTR); } #endif - SCM_SYSCALL (c = (scm_ptobs[i].fgetc) (f)); + SCM_SYSCALL (c = (scm_ptobs[i].fgetc) (port)); } if (c == '\n') |