From 21c7ef743b52fd3b30c8f4320b2120c4b39b4d99 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Hugo=20H=C3=B6rnquist?= Date: Fri, 14 Feb 2020 00:20:44 +0100 Subject: Months once again start on the first. --- module/srfi/srfi-19/alt.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'module/srfi/srfi-19/alt.scm') diff --git a/module/srfi/srfi-19/alt.scm b/module/srfi/srfi-19/alt.scm index 33a1bc1f..c07bcbd8 100644 --- a/module/srfi/srfi-19/alt.scm +++ b/module/srfi/srfi-19/alt.scm @@ -282,7 +282,7 @@ (define-values (days-fixed change*) (let loop ((target base) (change change)) ;; (format (current-error-port) "1 ~s : ~s~%" target change) - (if (> (days-in-month target) (+ (day change) (day target))) + (if (>= (days-in-month target) (+ (day change) (day target))) ;; No date overflow, just add the change (values (set-> target (day = (+ (day change)))) (set-> change (day 0))) -- cgit v1.2.3