diff options
Diffstat (limited to '')
-rw-r--r-- | module/vcomponent/recurrence/parse.scm | 17 |
1 files changed, 6 insertions, 11 deletions
diff --git a/module/vcomponent/recurrence/parse.scm b/module/vcomponent/recurrence/parse.scm index 36026899..c72ec367 100644 --- a/module/vcomponent/recurrence/parse.scm +++ b/module/vcomponent/recurrence/parse.scm @@ -9,6 +9,7 @@ #:use-module (srfi srfi-26) #:use-module (vcomponent recurrence internal) #:use-module (util) + #:use-module (util exceptions) #:use-module (ice-9 match)) @@ -52,10 +53,11 @@ ,@(map (match-lambda ((key guard '=> body ...) `((,key) (if (not ,guard) - (begin (warning (quote ,key) - (quote ,guard) - (list ,@guard) - ) + (begin (warning + "RRULE guard failed for key ~a~% guard: ~a : ~s" + ,key ,guard (map (lambda (o) (if (procedure? o) + (procedure-name o) + o)) ,@guard)) ,@else-clause) (begin ,@body)))) ((key body ...) @@ -64,13 +66,6 @@ `(else ,@body))) cases)))) -(define (warning key guard extra) - (display (format #f "Warning RRULE guard failed for key ~a~% guard: ~a : ~s~%" - key guard (map (lambda (o) (if (procedure? o) - (procedure-name o) - o)) extra)) - (current-error-port))) - ;; RFC 5545, Section 3.3.10. Recurrence Rule, states that the UNTIL value MUST have ;; the same type as the DTSTART of the event (date or datetime). I have seen events |