unofficial mirror of bug-guile@gnu.org 
 help / color / mirror / Atom feed
From: anonymous <INVALID.NOREPLY@gnu.org>
To: bug-guile@gnu.org
Subject: [bug #19807] srfi-19: current-time return type inconsistency
Date: Sat, 05 May 2007 14:23:41 +0000	[thread overview]
Message-ID: <20070505-142340.sv0.69710@savannah.gnu.org> (raw)
In-Reply-To: 


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/



_______________________________________________
Bug-guile mailing list
Bug-guile@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-guile


             reply	other threads:[~2007-05-05 14:23 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-05-05 14:23 anonymous [this message]
2007-05-06  8:37 ` [bug #19807] srfi-19: current-time return type inconsistency anonymous
2007-05-09 21:17   ` Ludovic Courtès
2007-05-10 13:20 ` Ludovic Courtès

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/guile/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20070505-142340.sv0.69710@savannah.gnu.org \
    --to=invalid.noreply@gnu.org \
    --cc=bug-guile@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).