[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Chicken-janitors] #829: srfi-19: time-monotonic->julian-day returns pro
From: |
Chicken Trac |
Subject: |
[Chicken-janitors] #829: srfi-19: time-monotonic->julian-day returns procedure, not value |
Date: |
Sun, 13 May 2012 09:51:47 -0000 |
#829: srfi-19: time-monotonic->julian-day returns procedure, not value
------------------------+---------------------------------------------------
Reporter: sjamaan | Owner: kon
Type: defect | Status: new
Priority: minor | Milestone: 4.9.0
Component: extensions | Version: 4.7.x
Keywords: srfi-19 |
------------------------+---------------------------------------------------
{{{
#;1> (use srfi-19)
#;2> (define t (current-time time-monotonic))
#;3> (time-monotonic->julian-day t)
#<procedure>
#;4> (#3 t) ;; This is of course incorrect
70734554131963/28800000
}}}
It looks like this is a small mistake which is simple to fix:
{{{
Index: srfi-19-support.scm
===================================================================
--- srfi-19-support.scm (revision 26685)
+++ srfi-19-support.scm (working copy)
@@ -1279,7 +1279,7 @@
(let ((sec (%time-second tim)))
(tm:seconds->julian-day (%time-nanosecond tim) (- sec (leap-second-
delta sec))) ) )
-(define (tm:time-monotonic->julian-day tim) tm:time-tai->julian-day)
+(define tm:time-monotonic->julian-day tm:time-tai->julian-day)
(define (tm:time->julian-day tim)
(case (%time-type tim)
}}}
This bug was found by the scrutinizer, see http://tests.call-
cc.org/master/linux/x86/2012/05/12/salmonella-report/install/srfi-19.html
(search for the string "Warning:")
--
Ticket URL: <http://bugs.call-cc.org/ticket/829>
Chicken Scheme <http://www.call-with-current-continuation.org/>
Chicken Scheme is a compiler for the Scheme programming language.
- [Chicken-janitors] #829: srfi-19: time-monotonic->julian-day returns procedure, not value,
Chicken Trac <=