Use module-ref for make-base-operation
As the implementation of this changed in fibers, and that's causing issues here when mixing the version of fibers used for knots and different versions of fibers.
This commit is contained in:
parent
21e328aebb
commit
f41d1853ce
1 changed files with 13 additions and 11 deletions
|
@ -119,17 +119,19 @@
|
|||
|
||||
(define (make-wait-operation ready? schedule-when-ready port
|
||||
port-ready-fd this-procedure)
|
||||
(make-base-operation #f
|
||||
(lambda _
|
||||
(and (ready? port) values))
|
||||
(lambda (flag sched resume)
|
||||
(define (commit)
|
||||
(match (atomic-box-compare-and-swap! flag 'W 'S)
|
||||
('W (resume values))
|
||||
('C (commit))
|
||||
('S #f)))
|
||||
(schedule-when-ready
|
||||
sched (port-ready-fd port) commit))))
|
||||
((module-ref (resolve-interface '(fibers operations))
|
||||
'make-base-operation)
|
||||
#f
|
||||
(lambda _
|
||||
(and (ready? port) values))
|
||||
(lambda (flag sched resume)
|
||||
(define (commit)
|
||||
(match (atomic-box-compare-and-swap! flag 'W 'S)
|
||||
('W (resume values))
|
||||
('C (commit))
|
||||
('S #f)))
|
||||
(schedule-when-ready
|
||||
sched (port-ready-fd port) commit))))
|
||||
|
||||
(define (wait-until-port-readable-operation port)
|
||||
"Make an operation that will succeed when PORT is readable."
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue