mirror of
https://github.com/ashinn/chibi-scheme.git
synced 2025-05-20 22:29:16 +02:00
adding port? predicate
This commit is contained in:
parent
6c074d686a
commit
69f3dcc3fd
1 changed files with 2 additions and 0 deletions
|
@ -525,6 +525,8 @@
|
|||
|
||||
;; I/O utils
|
||||
|
||||
(define (port? x) (or (input-port? x) (output-port? x)))
|
||||
|
||||
(define (char-ready? . o)
|
||||
(not (eof-object? (peek-char (if (pair? o) (car o) (current-input-port))))))
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue