mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-06-11 22:31:12 +02:00
Consume a peeked EOF at the REPL.
* module/system/repl/repl.scm (meta-reader): Consume peeked EOF.
This commit is contained in:
parent
7f3be1db99
commit
7520a9b95d
1 changed files with 2 additions and 5 deletions
|
@ -87,12 +87,9 @@
|
|||
(lambda ()
|
||||
(let ((ch (flush-leading-whitespace)))
|
||||
(cond ((eof-object? ch)
|
||||
;; EOF objects are not buffered. It's quite possible
|
||||
;; to peek an EOF then read something else. It's
|
||||
;; strange but it's how it works.
|
||||
ch)
|
||||
(read-char)) ; consume the EOF and return it
|
||||
((eqv? ch #\,)
|
||||
(read-char port)
|
||||
(read-char)
|
||||
meta-command-token)
|
||||
((read-comment lang port ch)
|
||||
*unspecified*)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue