fixing non-string-stream read-line to return eof when no data is read

This commit is contained in:
Alex Shinn 2012-05-19 07:38:54 +09:00
parent 7dd7d076dd
commit e8c0328540

View file

@ -54,7 +54,8 @@
(let ((ch (read-char in))) (let ((ch (read-char in)))
(cond (cond
((eof-object? ch) ((eof-object? ch)
(get-output-string out)) (let ((res (get-output-string out)))
(and (not (equal? res "")) res)))
(else (else
(write-char ch out) (write-char ch out)
(if (eqv? ch #\newline) (if (eqv? ch #\newline)