diff options
author | Andreas Rottmann <a.rottmann@gmx.at> | 2011-03-13 22:39:14 +0100 |
---|---|---|
committer | Ludovic Courtès <ludo@gnu.org> | 2011-03-13 22:39:14 +0100 |
commit | a6c377f7d8a311b0ce4f9c5900b1c81c27b2d60c (patch) | |
tree | 7a4bc6be9ea639d40c53385b1e2858ed717a8099 /module/rnrs.scm | |
parent | ca33b501a93f8de389c1e3e1bc987f63b6912029 (diff) | |
download | guile-a6c377f7d8a311b0ce4f9c5900b1c81c27b2d60c.tar.gz |
Add `get-string-n' and `get-string-n!' for R6RS ports
* libguile/r6rs-ports.c (scm_get_string_n_x): Implement `get-string-n!'
in C for efficiency.
* libguile/r6rs-ports.h: Add prototype for this function.
* module/ice-9/binary-ports.scm: Export `get-string-n!'.
* module/rnrs/io/ports.scm (get-string-n): Implement based on
`get-string-n!'.
Export both `get-string-n!' and `get-string-n'.
* module/rnrs.scm: Also export these.
* test-suite/tests/r6rs-ports.test (8.2.9 Textual input): Add a few
tests for `get-string-n' and `get-string-n!'.
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
Diffstat (limited to 'module/rnrs.scm')
-rw-r--r-- | module/rnrs.scm | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/module/rnrs.scm b/module/rnrs.scm index 476a3ab2d..77090d0e1 100644 --- a/module/rnrs.scm +++ b/module/rnrs.scm @@ -182,7 +182,8 @@ make-custom-textual-output-port call-with-string-output-port flush-output-port put-string - get-char get-datum get-line get-string-all lookahead-char + get-char get-datum get-line get-string-all get-string-n get-string-n! + lookahead-char put-char put-datum put-string standard-input-port standard-output-port standard-error-port |