From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Nathaniel Flath Newsgroups: gmane.emacs.devel Subject: alias time-to-seconds to float-time Date: Wed, 26 Aug 2009 21:33:19 -0700 Message-ID: <5e3a506e0908262133y5ecbff5fme2c0aa47889484ca@mail.gmail.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=000e0cd2c0d02a659a04721811de X-Trace: ger.gmane.org 1251347627 30365 80.91.229.12 (27 Aug 2009 04:33:47 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 27 Aug 2009 04:33:47 +0000 (UTC) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu Aug 27 06:33:40 2009 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1MgWg6-0007XM-Bp for ged-emacs-devel@m.gmane.org; Thu, 27 Aug 2009 06:33:38 +0200 Original-Received: from localhost ([127.0.0.1]:33123 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MgWg5-0006ty-L4 for ged-emacs-devel@m.gmane.org; Thu, 27 Aug 2009 00:33:37 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MgWg0-0006tJ-Ik for emacs-devel@gnu.org; Thu, 27 Aug 2009 00:33:32 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MgWfv-0006oJ-7l for emacs-devel@gnu.org; Thu, 27 Aug 2009 00:33:31 -0400 Original-Received: from [199.232.76.173] (port=38842 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MgWfv-0006o6-2Q for emacs-devel@gnu.org; Thu, 27 Aug 2009 00:33:27 -0400 Original-Received: from mx20.gnu.org ([199.232.41.8]:8860) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1MgWfu-0005om-Li for emacs-devel@gnu.org; Thu, 27 Aug 2009 00:33:26 -0400 Original-Received: from mail-px0-f176.google.com ([209.85.216.176]) by mx20.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1MgWfs-0003nP-OJ for emacs-devel@gnu.org; Thu, 27 Aug 2009 00:33:24 -0400 Original-Received: by pxi6 with SMTP id 6so815554pxi.27 for ; Wed, 26 Aug 2009 21:33:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:date:message-id:subject :from:to:content-type; bh=YtmdOMICQg6qPmP5QXprfbyOYSwvhD+dhYH7XLSzubg=; b=xoGI2Wkes76LUj7ruEG8S/V1lqIFGokKhA1bnVvvRSShkxeWi1iVQSm3ZxXml2Fh5+ tk0efND83VVLMLwzQXnKnBReye3SRnY1nhXM6qakNMNxfF3phF+g5Qwb9JgcOvzxGAAK z/Tz7kcjx22TIxVLgiE6iSr70gxkeDk1J2Hk4= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type; b=gURCaxFL1whyaIia/nSFZR9SbNDV3Q6vft73hp19o1O3xSOsOVvMK6svEjWH16w+12 yT5XItpm8Bc4WSTftbL8L6Ud6VA1s9xqTc2+zthssQg6M5RUrxT7RMt71Wg1shOP6eMu NOhU7x/O7NpIp4wZyqT6JlmvNGkmcOShDEsno= Original-Received: by 10.141.41.11 with SMTP id t11mr4132356rvj.259.1251347599615; Wed, 26 Aug 2009 21:33:19 -0700 (PDT) X-Detected-Operating-System: by mx20.gnu.org: GNU/Linux 2.6 (newer, 2) X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6, seldom 2.4 (older, 4) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:114663 Archived-At: --000e0cd2c0d02a659a04721811de Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit >From the time-to-seconds doc-string: "Convert time value TIME to a floating point number. You can use `float-time' instead." Looking at both functions, there doesn't seem to be any difference other than float-time being implemented in C. Should time-to-seconds just be aliased to float-time? Patch to time-date.el: < ;;;###autoload < (defun time-to-seconds (time) < "Convert time value TIME to a floating point number. < You can use `float-time' instead." < (with-decoded-time-value ((high low micro time)) < (+ (* 1.0 high 65536) < low < (/ micro 1000000.0)))) --- > (defalias 'time-to-seconds 'float-time) Thanks, Nathaniel Flath --000e0cd2c0d02a659a04721811de Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable >From the time-to-seconds doc-string:
"Convert time value TIME to a = floating point number.=A0 You can use `float-time' instead."
Lo= oking at both functions, there doesn't seem to be any difference other = than float-time being implemented in C.=A0 Should time-to-seconds just be a= liased to float-time?

Patch to time-date.el:
< ;;;###autoload
< (defun time-to-se= conds (time)
<=A0=A0 "Convert time value TIME to a floating poin= t number.
< You can use `float-time' instead."
<=A0=A0= (with-decoded-time-value ((high low micro time))
<=A0=A0=A0=A0 (+ (* 1.0 high 65536)
<=A0=A0=A0=A0=A0=A0=A0 low
= <=A0=A0=A0=A0=A0=A0=A0 (/ micro 1000000.0))))
---
> (defalias &= #39;time-to-seconds 'float-time)

Thanks,
Nathaniel Flath
--000e0cd2c0d02a659a04721811de--