summaryrefslogtreecommitdiff
path: root/libguile/vports.c
diff options
context:
space:
mode:
authorMikael Djurfeldt <djurfeldt@nada.kth.se>2000-01-18 11:24:37 +0000
committerMikael Djurfeldt <djurfeldt@nada.kth.se>2000-01-18 11:24:37 +0000
commitd3818c298266c5f1d28a33f58da92471cfd66e66 (patch)
treec779afbb5473fb25dbeea3e408d33807a65cc782 /libguile/vports.c
parentb380b88547226544d5a2b7d09379c79fbe300e10 (diff)
downloadguile-d3818c298266c5f1d28a33f58da92471cfd66e66.tar.gz
* alist.c, chars.c, debug.c, dynl.c, dynwind.c, error.c, eval.c,
evalext.c, filesys.c, gc.c, hash.c, hashtab.c, ioext.c, keywords.c, list.c, load.c, macros.c, net_db.c, numbers.c, objprop.c, ports.c, posix.c, print.c, procprop.c, procs.c, ramap.c, regex-posix.c, root.c, scmsigs.c, simpos.c, socket.c, stacks.c, stime.c, strings.c, strop.c, strports.c, struct.c, symbols.c, throw.c, unif.c, vectors.c, version.c, vports.c, weaks.c: Converted docstrings to ANSI C format. * filesys.c (scm_chmod), simpos.c (s_scm_system), version (scm_version), vports (scm_make_soft_port): Escape " occuring inside docstring.
Diffstat (limited to 'libguile/vports.c')
-rw-r--r--libguile/vports.c75
1 files changed, 35 insertions, 40 deletions
diff --git a/libguile/vports.c b/libguile/vports.c
index df7c6928c..89cc35cd7 100644
--- a/libguile/vports.c
+++ b/libguile/vports.c
@@ -139,46 +139,41 @@ sf_close (SCM port)
SCM_DEFINE (scm_make_soft_port, "make-soft-port", 2, 0, 0,
(SCM pv, SCM modes),
-"Returns a port capable of receiving or delivering characters as
-specified by the @var{modes} string (@pxref{File Ports,
-open-file}). @var{vector} must be a vector of length 6. Its components
-are as follows:
-
-@enumerate 0
-@item
-procedure accepting one character for output
-@item
-procedure accepting a string for output
-@item
-thunk for flushing output
-@item
-thunk for getting one character
-@item
-thunk for closing port (not by garbage collection)
-@end enumerate
-
-For an output-only port only elements 0, 1, 2, and 4 need be
-procedures. For an input-only port only elements 3 and 4 need be
-procedures. Thunks 2 and 4 can instead be @code{#f} if there is no useful
-operation for them to perform.
-
-If thunk 3 returns @code{#f} or an @code{eof-object} (@pxref{Input,
-eof-object?, ,r4rs, The Revised^4 Report on Scheme}) it indicates that
-the port has reached end-of-file. For example:
-
-@example
-(define stdout (current-output-port))
-(define p (make-soft-port
- (vector
- (lambda (c) (write c stdout))
- (lambda (s) (display s stdout))
- (lambda () (display "." stdout))
- (lambda () (char-upcase (read-char)))
- (lambda () (display "@@" stdout)))
- "rw"))
-
-(write p p) @result{} #<input-output-soft#\space45d10#\>
-@end example")
+ "Returns a port capable of receiving or delivering characters as\n"
+ "specified by the @var{modes} string (@pxref{File Ports,\n"
+ "open-file}). @var{vector} must be a vector of length 6. Its components\n"
+ "are as follows:\n\n"
+ "@enumerate 0\n"
+ "@item\n"
+ "procedure accepting one character for output\n"
+ "@item\n"
+ "procedure accepting a string for output\n"
+ "@item\n"
+ "thunk for flushing output\n"
+ "@item\n"
+ "thunk for getting one character\n"
+ "@item\n"
+ "thunk for closing port (not by garbage collection)\n"
+ "@end enumerate\n\n"
+ "For an output-only port only elements 0, 1, 2, and 4 need be\n"
+ "procedures. For an input-only port only elements 3 and 4 need be\n"
+ "procedures. Thunks 2 and 4 can instead be @code{#f} if there is no useful\n"
+ "operation for them to perform.\n\n"
+ "If thunk 3 returns @code{#f} or an @code{eof-object} (@pxref{Input,\n"
+ "eof-object?, ,r4rs, The Revised^4 Report on Scheme}) it indicates that\n"
+ "the port has reached end-of-file. For example:\n\n"
+ "@example\n"
+ "(define stdout (current-output-port))\n"
+ "(define p (make-soft-port\n"
+ " (vector\n"
+ " (lambda (c) (write c stdout))\n"
+ " (lambda (s) (display s stdout))\n"
+ " (lambda () (display \".\" stdout))\n"
+ " (lambda () (char-upcase (read-char)))\n"
+ " (lambda () (display \"@@\" stdout)))\n"
+ " \"rw\"))\n\n"
+ "(write p p) @result{} #<input-output-soft#\space45d10#\>\n"
+ "@end example")
#define FUNC_NAME s_scm_make_soft_port
{
scm_port *pt;