mirror of
https://github.com/ashinn/chibi-scheme.git
synced 2025-07-04 11:46:37 +02:00
Renaming the (chibi io) simple version of string-count to string-count-chars.
This commit is contained in:
parent
eb58aa9328
commit
4b805751f6
3 changed files with 4 additions and 4 deletions
|
@ -8,7 +8,7 @@
|
||||||
make-null-output-port make-null-input-port
|
make-null-output-port make-null-input-port
|
||||||
make-broadcast-port make-concatenated-port
|
make-broadcast-port make-concatenated-port
|
||||||
make-generated-input-port make-filtered-output-port
|
make-generated-input-port make-filtered-output-port
|
||||||
make-filtered-input-port string-count
|
make-filtered-input-port string-count-chars
|
||||||
open-input-bytevector open-output-bytevector get-output-bytevector
|
open-input-bytevector open-output-bytevector get-output-bytevector
|
||||||
string->utf8 utf8->string
|
string->utf8 utf8->string
|
||||||
write-string write-u8 read-u8 peek-u8 send-file
|
write-string write-u8 read-u8 peek-u8 send-file
|
||||||
|
|
|
@ -136,7 +136,7 @@
|
||||||
((if (pair? res) (= 0 (car res)) #t)
|
((if (pair? res) (= 0 (car res)) #t)
|
||||||
eof)
|
eof)
|
||||||
(else
|
(else
|
||||||
(port-line-set! in (+ (string-count #\newline (cadr res) 0)
|
(port-line-set! in (+ (string-count-chars #\newline (cadr res) 0)
|
||||||
(port-line in)))
|
(port-line in)))
|
||||||
(cadr res)))))))
|
(cadr res)))))))
|
||||||
|
|
||||||
|
@ -161,7 +161,7 @@
|
||||||
(error "string to small to read chars" str n))
|
(error "string to small to read chars" str n))
|
||||||
(let* ((in (if (pair? o) (car o) (current-input-port)))
|
(let* ((in (if (pair? o) (car o) (current-input-port)))
|
||||||
(res (%read-string! str n in)))
|
(res (%read-string! str n in)))
|
||||||
(port-line-set! in (+ (string-count #\newline str 0 n) (port-line in)))
|
(port-line-set! in (+ (string-count-chars #\newline str 0 n) (port-line in)))
|
||||||
res))
|
res))
|
||||||
|
|
||||||
;;> Sends the entire contents of a file or input port to an output port.
|
;;> Sends the entire contents of a file or input port to an output port.
|
||||||
|
|
|
@ -38,7 +38,7 @@
|
||||||
(define-c sexp (get-output-bytevector "sexp_get_output_bytevector")
|
(define-c sexp (get-output-bytevector "sexp_get_output_bytevector")
|
||||||
((value ctx sexp) (value self sexp) sexp))
|
((value ctx sexp) (value self sexp) sexp))
|
||||||
|
|
||||||
(define-c sexp (string-count "sexp_string_count")
|
(define-c sexp (string-count-chars "sexp_string_count")
|
||||||
((value ctx sexp) (value self sexp) sexp sexp sexp (default NULL sexp)))
|
((value ctx sexp) (value self sexp) sexp sexp sexp (default NULL sexp)))
|
||||||
(define-c sexp (%string->utf8 "sexp_string_to_utf8")
|
(define-c sexp (%string->utf8 "sexp_string_to_utf8")
|
||||||
((value ctx sexp) (value self sexp) sexp))
|
((value ctx sexp) (value self sexp) sexp))
|
||||||
|
|
Loading…
Add table
Reference in a new issue