aboutsummaryrefslogtreecommitdiff
path: root/module/vcomponent/group.scm
diff options
context:
space:
mode:
authorHugo Hörnquist <hugo@hornquist.se>2019-10-05 23:58:03 +0200
committerHugo Hörnquist <hugo@hornquist.se>2019-10-05 23:58:03 +0200
commit68dfd8bb5abcc449500614c46566ffa4a83177a4 (patch)
treee1259834ad04db9fe2db7fec526cf4fd52b26990 /module/vcomponent/group.scm
parentFix day-stream, and in effect terminal output. (diff)
downloadcalp-68dfd8bb5abcc449500614c46566ffa4a83177a4.tar.gz
calp-68dfd8bb5abcc449500614c46566ffa4a83177a4.tar.xz
Documentation of stream behavior.
Diffstat (limited to 'module/vcomponent/group.scm')
-rw-r--r--module/vcomponent/group.scm5
1 files changed, 5 insertions, 0 deletions
diff --git a/module/vcomponent/group.scm b/module/vcomponent/group.scm
index 7733d981..46160a3a 100644
--- a/module/vcomponent/group.scm
+++ b/module/vcomponent/group.scm
@@ -20,6 +20,11 @@
(let ((head (stream-take-while (ein? day) stream))
(tail
+ ;; This is a filter, instead of a stream-span together with head,
+ ;; since events can span multiple days.
+ ;; This starts with taking everything which end after the beginning
+ ;; of tommorow, and finishes with the rest when it finds the first
+ ;; object which begins tomorow (after midnight, exclusize).
(filter-sorted-stream*
(lambda (e) (time<? tomorow (attr e 'DTEND)))
(lambda (e) (time<=? tomorow (attr e 'DTSTART)))