guile-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Guile-commits] 01/02: SRFI-19: time-utc->date: Support non-integer nano


From: Mark H. Weaver
Subject: [Guile-commits] 01/02: SRFI-19: time-utc->date: Support non-integer nanoseconds values.
Date: Wed, 24 Oct 2018 01:16:15 -0400 (EDT)

mhw pushed a commit to branch stable-2.2
in repository guile.

commit ac1fa8dba4791feb545744a89192e0d368c5f5a6
Author: Mark H Weaver <address@hidden>
Date:   Mon Oct 22 03:21:40 2018 -0400

    SRFI-19: time-utc->date: Support non-integer nanoseconds values.
    
    * module/srfi/srfi-19.scm (time-utc->date): Use 'floor-remainder'
    instead of 'modulo'.
---
 module/srfi/srfi-19.scm | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/module/srfi/srfi-19.scm b/module/srfi/srfi-19.scm
index 2f5f322..5ab5d89 100644
--- a/module/srfi/srfi-19.scm
+++ b/module/srfi/srfi-19.scm
@@ -639,7 +639,7 @@
                (rem      (remainder int-secs (* 60 60)))
                (minutes  (quotient rem 60))
                (seconds  (remainder rem 60)))
-          (make-date (modulo nanoseconds nano)
+          (make-date (floor-remainder nanoseconds nano)
                      seconds
                      minutes
                      hours



reply via email to

[Prev in Thread] Current Thread [Next in Thread]