- added EOF clause to interact
This commit is contained in:
parent
0a2217bc5c
commit
96fccbe6b0
|
@ -113,12 +113,14 @@
|
||||||
(else (error "Only character-patterns are supported."))))))
|
(else (error "Only character-patterns are supported."))))))
|
||||||
|
|
||||||
(define-syntax interact-clauses
|
(define-syntax interact-clauses
|
||||||
(syntax-rules (timeout)
|
(syntax-rules (timeout eof)
|
||||||
((interact-clauses) (cons #f '()))
|
((interact-clauses) (cons #f '()))
|
||||||
((interact-clauses (timeout secs handler) rest ...)
|
((interact-clauses (timeout secs handler) rest ...)
|
||||||
(let ((r (interact-clauses rest ...)))
|
(let ((r (interact-clauses rest ...)))
|
||||||
(cons (cons secs handler)
|
(cons (cons secs handler)
|
||||||
(cdr r))))
|
(cdr r))))
|
||||||
|
((interact-clauses (eof (flag ...) body ...) rest ...)
|
||||||
|
(interact-clauses (eof-pattern (flag ...) (cont ignore) body ...) rest ...))
|
||||||
((interact-clauses (rx (flag ...) (cont match mvar ...) body ...) rest ...)
|
((interact-clauses (rx (flag ...) (cont match mvar ...) body ...) rest ...)
|
||||||
(let ((r (interact-clauses rest ...)))
|
(let ((r (interact-clauses rest ...)))
|
||||||
(cons (car r)
|
(cons (car r)
|
||||||
|
|
Loading…
Reference in New Issue