projects
/
8sync.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
maybe use pfds instead??
[8sync.git]
/
loopy.scm
diff --git
a/loopy.scm
b/loopy.scm
index e03cab6ae59d03ec34b72cd84f511f3ec6ca8c00..a77b7927d835886527c999168a6d5dfd1b87a195 100644
(file)
--- a/
loopy.scm
+++ b/
loopy.scm
@@
-4,7
+4,7
@@
(ice-9 match))
;; @@: Using immutable agendas here, so wouldn't it make sense to
(ice-9 match))
;; @@: Using immutable agendas here, so wouldn't it make sense to
-;; replace this
+;; replace this
queue stuff with using pfds based immutable queues?
(define-immutable-record-type <agenda>
(make-agenda-intern queue prompt-tag)
(define-immutable-record-type <agenda>
(make-agenda-intern queue prompt-tag)
@@
-24,7
+24,10
@@
(define* (start-agenda agenda #:optional stop-condition)
(let loop ((agenda agenda))
(define* (start-agenda agenda #:optional stop-condition)
(let loop ((agenda agenda))
- (let ((new-agenda
+ (let ((new-agenda
+ ;; @@: Hm, maybe here would be a great place to handle
+ ;; select'ing on ports.
+ ;; We could compose over agenda-run-once and agenda-read-ports
(parameterize ((%current-agenda agenda))
(agenda-run-once agenda))))
(if (and stop-condition (stop-condition agenda))
(parameterize ((%current-agenda agenda))
(agenda-run-once agenda))))
(if (and stop-condition (stop-condition agenda))