Skip to content

Commit

Permalink
fix "reboot" script for #vfl in included
Browse files Browse the repository at this point in the history
  • Loading branch information
mflatt committed Mar 9, 2023
1 parent ba91fd4 commit baa8803
Showing 1 changed file with 11 additions and 3 deletions.
14 changes: 11 additions & 3 deletions s/reboot.ss
Original file line number Diff line number Diff line change
Expand Up @@ -541,8 +541,13 @@
fn)

(define-primitive ($make-read p . more)
(lambda ()
(read p)))
(let ([l (filtered-file->exps p)])
(lambda ()
(if (null? l)
#!eof
(let ([a (car l)])
(set! l (cdr l))
a)))))

(define-primitive ($map who f . ls)
(apply map f ls))
Expand Down Expand Up @@ -575,7 +580,9 @@
(define (filtered-file->exps s)
(cond
[need-vector-filter?
(call-with-input-file
((if (input-port? s)
(lambda (s proc) (proc s))
call-with-input-file)
s
(lambda (i)
(let* ([str (get-string-all i)]
Expand Down Expand Up @@ -627,6 +634,7 @@
(vec-loop (add1 i))))
v)]
[else r]))))))]
[(input-port? s) (input->exps s)]
[else (file->exps s)]))

(define (noisy-compile-and-load s)
Expand Down

0 comments on commit baa8803

Please sign in to comment.