Ensure that chaos is stopped on exceptions
This commit is contained in:
parent
93edd8a8b1
commit
e5cd1f303f
3
word.rkt
3
word.rkt
|
@ -84,8 +84,7 @@
|
||||||
(define (call-with-chaos c t)
|
(define (call-with-chaos c t)
|
||||||
(chaos-start! c)
|
(chaos-start! c)
|
||||||
(parameterize ([current-chaos c])
|
(parameterize ([current-chaos c])
|
||||||
(begin0 (t)
|
(dynamic-wind void t (λ () (chaos-stop! c)))))
|
||||||
(chaos-stop! c))))
|
|
||||||
|
|
||||||
(define (fiat-lux w)
|
(define (fiat-lux w)
|
||||||
(define c (current-chaos))
|
(define c (current-chaos))
|
||||||
|
|
Loading…
Reference in New Issue