fix initialization error

This commit is contained in:
Jay McCarthy 2014-04-16 15:27:36 -06:00
parent 62466ddf9e
commit df3a082d1e

View File

@ -412,6 +412,17 @@
(current-inexact-milliseconds))
empty)]
[head last]
[consumer (proc->signal
(lambda ()
(let* ([now (current-inexact-milliseconds)]
[new (deep-value-now beh empty)]
[ms (value-now ms-b)])
(when (not (equal? new (car (mcar last))))
(set-mcdr! last (mcons (cons new now)
empty))
(set! last (mcdr last))
(schedule-alarm (+ now ms) producer))))
beh ms-b)]
[producer (proc->signal
(lambda ()
(let* ([now (and (signal? consumer) (current-inexact-milliseconds))]
@ -425,18 +436,7 @@
val))
(begin
(set! head (mcdr head))
(loop)))))))]
[consumer (proc->signal
(lambda ()
(let* ([now (current-inexact-milliseconds)]
[new (deep-value-now beh empty)]
[ms (value-now ms-b)])
(when (not (equal? new (car (mcar last))))
(set-mcdr! last (mcons (cons new now)
empty))
(set! last (mcdr last))
(schedule-alarm (+ now ms) producer))))
beh ms-b)])
(loop)))))))])
producer))
(define (inf-delay beh)