diff options
author | Hugo Hörnquist <hugo@lysator.liu.se> | 2020-07-04 03:24:31 +0200 |
---|---|---|
committer | Hugo Hörnquist <hugo@lysator.liu.se> | 2020-07-07 13:10:38 +0200 |
commit | e9a37e667c4c7fabb051c6256527bcb849e300b8 (patch) | |
tree | 6bc151e5b4f99d43339ea984388f229df3f57377 /module/vcomponent | |
parent | Replace #$ reader macro with define-foreign. (diff) | |
download | calp-e9a37e667c4c7fabb051c6256527bcb849e300b8.tar.gz calp-e9a37e667c4c7fabb051c6256527bcb849e300b8.tar.xz |
Replace datetime literals with proper sexps.
Diffstat (limited to 'module/vcomponent')
-rw-r--r-- | module/vcomponent/datetime.scm | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/module/vcomponent/datetime.scm b/module/vcomponent/datetime.scm index 79ebb5f5..85b37d6d 100644 --- a/module/vcomponent/datetime.scm +++ b/module/vcomponent/datetime.scm @@ -91,7 +91,7 @@ Event must have the DTSTART and DTEND protperty set." (define-public (event-length/day date e) (if (not (prop e 'DTEND)) (if (date? (prop e 'DTSTART)) - #24:00:00 + (time hour: 24) (time)) (let ((start (prop e 'DTSTART)) (end (prop e 'DTEND))) @@ -99,12 +99,12 @@ Event must have the DTSTART and DTEND protperty set." (time- (as-time end) (as-time start))] ;; Starts today, end in future day [(date= date (as-date start)) - (time- #24:00:00 (as-time start))] + (time- (time hour: 24) (as-time start))] ;; Ends today, start earlier day [(date= date (as-date end)) (as-time end)] ;; start earlier date, end later date - [else #24:00:00])))) + [else (time hour: 24)])))) ;; 22:00 - 03:00 @@ -199,7 +199,7 @@ Event must have the DTSTART and DTEND protperty set." ;; event is for limiter (define-public (zoneinfo->vtimezone zoneinfo zone-name event) (define vtimezone (make-vcomponent 'VTIMEZONE)) - (define last-until (datetime date: #1000-01-01)) + (define last-until (datetime date: (date month: 1 day: 1))) (define last-offset (timespec-zero)) (set! (prop vtimezone 'TZID) zone-name) |