bug-guile
[Top][All Lists]
Advanced

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

[bug #19807] srfi-19: current-time return type inconsistency


From: anonymous
Subject: [bug #19807] srfi-19: current-time return type inconsistency
Date: Sat, 05 May 2007 14:23:41 +0000
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8.1.3) Gecko/20070310 Iceweasel/2.0.0.3 (Debian-2.0.0.3-2)

URL:
  <http://savannah.gnu.org/bugs/?19807>

                 Summary: srfi-19: current-time return type inconsistency
                 Project: Guile
            Submitted by: None
            Submitted on: Saturday 05/05/07 at 14:23 UTC
                Category: None
                Severity: 3 - Normal
              Item Group: None
                  Status: None
                 Privacy: Public
             Assigned to: None
             Open/Closed: Open
         Discussion Lock: Any

    _______________________________________________________

Details:

The procedure current-time in srfi-19 returns a time record:

  guile> (current-time)
  #<time type: time-utc nanosecond: ...

...except when the time type time-process is requested in which case a list
is returned:

  guile> (current-time time-process)
  (time-process ...

This causes other functionality to break, for example time-difference:

  guile> (time-difference
           (current-time)
           (current-time))
  #<time type: time-duration nanosecond: ...

  guile> (time-difference
           (current-time time-process)
           (current-time time-process))
  ...
  ... not-a-record (time-process ...
  ABORT: (misc-error)

Suggested fix:

There are two definitions of priv:current-time-process in srfi-19.scm. The
first returns a time record, and second returns the list. Commenting out the
second gives me the behavior I expected.

thanks for your time,
Scott Shedden





    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?19807>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/





reply via email to

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