diff options
author | David Thompson <dthompson2@worcester.edu> | 2014-01-07 20:26:00 -0500 |
---|---|---|
committer | David Thompson <dthompson2@worcester.edu> | 2014-01-07 20:26:00 -0500 |
commit | 993f01e6a0ee47c08dfcfd1426527b2d699b8893 (patch) | |
tree | 857c7d830a16a3727def26e125c612f3eb1160de /2d | |
parent | 15a7f546cb2107153777d420e824dce2f79d2db1 (diff) |
Use SRFI-26 in agenda module.
* 2d/agenda.scm (make-time-segment, wait): Use cut.
Diffstat (limited to '2d')
-rw-r--r-- | 2d/agenda.scm | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/2d/agenda.scm b/2d/agenda.scm index cf39932..bf86f22 100644 --- a/2d/agenda.scm +++ b/2d/agenda.scm @@ -25,6 +25,7 @@ #:use-module (ice-9 q) #:use-module (srfi srfi-1) #:use-module (srfi srfi-9) + #:use-module (srfi srfi-26) #:use-module (2d coroutine) #:export (make-agenda *global-agenda* @@ -56,7 +57,7 @@ list CALLBACKS." (let ((segment (%make-time-segment time (make-q)))) ;; Enqueue all callbacks - (for-each (lambda (c) (segment-enq segment c)) callbacks) + (for-each (cut segment-enq segment <>) callbacks) segment)) (define (segment-enq segment callback) @@ -208,4 +209,4 @@ tick." (define* (wait #:optional (delay 1)) "Yield coroutine and schdule the continuation to be run after DELAY ticks." - (yield (lambda (resume) (schedule resume delay)))) + (yield (cut schedule <> delay))) |