From debbugs-submit-bounces@debbugs.gnu.org Sun Dec 04 15:57:11 2016 Received: (at submit) by debbugs.gnu.org; 4 Dec 2016 20:57:11 +0000 Received: from localhost ([127.0.0.1]:56197 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cDdqR-0000cV-Hp for submit@debbugs.gnu.org; Sun, 04 Dec 2016 15:57:11 -0500 Received: from eggs.gnu.org ([208.118.235.92]:41803) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cDdqO-0000cH-Es for submit@debbugs.gnu.org; Sun, 04 Dec 2016 15:57:09 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cDdqI-0000Tn-Mr for submit@debbugs.gnu.org; Sun, 04 Dec 2016 15:57:03 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50 autolearn=disabled version=3.3.2 Received: from lists.gnu.org ([2001:4830:134:3::11]:41461) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1cDdqI-0000Tj-Jx for submit@debbugs.gnu.org; Sun, 04 Dec 2016 15:57:02 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:61000) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cDdqH-0002cJ-FC for bug-gnu-emacs@gnu.org; Sun, 04 Dec 2016 15:57:02 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cDdqC-0000SO-KA for bug-gnu-emacs@gnu.org; Sun, 04 Dec 2016 15:57:01 -0500 Received: from userp1040.oracle.com ([156.151.31.81]:21059) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1cDdqC-0000Ro-BY for bug-gnu-emacs@gnu.org; Sun, 04 Dec 2016 15:56:56 -0500 Received: from aserv0022.oracle.com (aserv0022.oracle.com [141.146.126.234]) by userp1040.oracle.com (Sentrion-MTA-4.3.2/Sentrion-MTA-4.3.2) with ESMTP id uB4KunOi013373 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK) for ; Sun, 4 Dec 2016 20:56:51 GMT Received: from aserv0121.oracle.com (aserv0121.oracle.com [141.146.126.235]) by aserv0022.oracle.com (8.14.4/8.14.4) with ESMTP id uB4KunfZ010889 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Sun, 4 Dec 2016 20:56:49 GMT Received: from abhmp0003.oracle.com (abhmp0003.oracle.com [141.146.116.9]) by aserv0121.oracle.com (8.13.8/8.13.8) with ESMTP id uB4KulIs004380 for ; Sun, 4 Dec 2016 20:56:48 GMT MIME-Version: 1.0 Message-ID: <5b95d9b8-3281-40da-872d-1a98b8a3d1fa@default> Date: Sun, 4 Dec 2016 12:56:47 -0800 (PST) From: Drew Adams To: bug-gnu-emacs@gnu.org Subject: 24.5; function to encode time from time string X-Priority: 3 X-Mailer: Oracle Beehive Extensions for Outlook 2.0.1.9.1 (1003210) [OL 12.0.6753.5000 (x86)] Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Source-IP: aserv0022.oracle.com [141.146.126.234] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic] [fuzzy] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 2001:4830:134:3::11 X-Spam-Score: -4.0 (----) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -4.0 (----) Enhancement request: Please add a function that accepts a time string and a format spec (to interpret the time string), and returns a time value that represents the same time. I could not find such a function mentioned in the manuals. I came across a need for such a thing when wanting to convert the :time entry of an Eww "bookmark" to a (SEC-HIGH SEC-LOW MICROSEC PICOSEC) list such as is returned by `current-time', for use in an ordinary Emacs bookmark. (I have no idea why Eww uses a string to record the time, as there is little you can do with it besides read it as a human. But it does.) (I have no idea why Eww uses its own, incompatible form of "bookmarks". But it does. And so does Org.) In GNU Emacs 24.5.1 (i686-pc-mingw32) of 2015-04-11 on LEG570 Windowing system distributor `Microsoft Corp.', version 6.1.7601 Configured using: `configure --prefix=3D/c/usr --host=3Di686-pc-mingw32' From debbugs-submit-bounces@debbugs.gnu.org Sun Dec 04 16:50:24 2016 Received: (at 25112) by debbugs.gnu.org; 4 Dec 2016 21:50:24 +0000 Received: from localhost ([127.0.0.1]:56217 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cDefv-0001sQ-Qy for submit@debbugs.gnu.org; Sun, 04 Dec 2016 16:50:24 -0500 Received: from userp1040.oracle.com ([156.151.31.81]:46050) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cDeft-0001sD-F4 for 25112@debbugs.gnu.org; Sun, 04 Dec 2016 16:50:22 -0500 Received: from userv0021.oracle.com (userv0021.oracle.com [156.151.31.71]) by userp1040.oracle.com (Sentrion-MTA-4.3.2/Sentrion-MTA-4.3.2) with ESMTP id uB4LoFuq012782 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK) for <25112@debbugs.gnu.org>; Sun, 4 Dec 2016 21:50:15 GMT Received: from aserv0121.oracle.com (aserv0121.oracle.com [141.146.126.235]) by userv0021.oracle.com (8.14.4/8.14.4) with ESMTP id uB4LoExK030591 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for <25112@debbugs.gnu.org>; Sun, 4 Dec 2016 21:50:15 GMT Received: from abhmp0003.oracle.com (abhmp0003.oracle.com [141.146.116.9]) by aserv0121.oracle.com (8.13.8/8.13.8) with ESMTP id uB4LoCPM016671 for <25112@debbugs.gnu.org>; Sun, 4 Dec 2016 21:50:13 GMT MIME-Version: 1.0 Message-ID: Date: Sun, 4 Dec 2016 13:50:13 -0800 (PST) From: Drew Adams To: 25112@debbugs.gnu.org Subject: RE: bug#25112: 24.5; function to encode time from time string References: <5b95d9b8-3281-40da-872d-1a98b8a3d1fa@default> In-Reply-To: <5b95d9b8-3281-40da-872d-1a98b8a3d1fa@default> X-Priority: 3 X-Mailer: Oracle Beehive Extensions for Outlook 2.0.1.9.1 (1003210) [OL 12.0.6753.5000 (x86)] Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Source-IP: userv0021.oracle.com [156.151.31.71] X-Spam-Score: -5.2 (-----) X-Debbugs-Envelope-To: 25112 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -5.2 (-----) FYI, I just now came across this library on Emacs Wiki: https://www.emacswiki.org/emacs/strptime.el It seems to have something similar to the requested enhancement. It is not something that I can use, and it is no replacement for the enhancement, but it might help. The copyright for it is by A. Aichner of XEmacs. The library description is this: partial implementation of POSIX date and time parsing Implemented (partially, specifically without locale support) according to http://www.opengroup.org/onlinepubs/009695399/functions/strptime.html The main function (command) it provides is this: (defun strptime (time format &optional extended) "Return a nine element list of TIME, parsed according to FORMAT..." From debbugs-submit-bounces@debbugs.gnu.org Mon Dec 05 11:08:44 2016 Received: (at 25112) by debbugs.gnu.org; 5 Dec 2016 16:08:44 +0000 Received: from localhost ([127.0.0.1]:57121 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cDvop-0002dM-RK for submit@debbugs.gnu.org; Mon, 05 Dec 2016 11:08:43 -0500 Received: from eggs.gnu.org ([208.118.235.92]:44722) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cDvoo-0002d7-3x for 25112@debbugs.gnu.org; Mon, 05 Dec 2016 11:08:42 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cDvof-00009F-GQ for 25112@debbugs.gnu.org; Mon, 05 Dec 2016 11:08:36 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-2.2 required=5.0 tests=BAYES_50,RP_MATCHES_RCVD autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:46761) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cDvof-00009B-DE; Mon, 05 Dec 2016 11:08:33 -0500 Received: from 84.94.185.246.cable.012.net.il ([84.94.185.246]:3282 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1cDvoe-0000Ol-NQ; Mon, 05 Dec 2016 11:08:33 -0500 Date: Mon, 05 Dec 2016 18:08:51 +0200 Message-Id: <83vauyjr3g.fsf@gnu.org> From: Eli Zaretskii To: Drew Adams In-reply-to: <5b95d9b8-3281-40da-872d-1a98b8a3d1fa@default> (message from Drew Adams on Sun, 4 Dec 2016 12:56:47 -0800 (PST)) Subject: Re: bug#25112: 24.5; function to encode time from time string References: <5b95d9b8-3281-40da-872d-1a98b8a3d1fa@default> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-Spam-Score: -7.9 (-------) X-Debbugs-Envelope-To: 25112 Cc: 25112@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Eli Zaretskii Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -7.9 (-------) > Date: Sun, 4 Dec 2016 12:56:47 -0800 (PST) > From: Drew Adams > > Enhancement request: Please add a function that accepts a time string > and a format spec (to interpret the time string), and returns a time > value that represents the same time. I believe you want either date-to-time or parse-time-string (the former is just a thin wrapper around the latter). date-to-time is described in the ELisp manual. From debbugs-submit-bounces@debbugs.gnu.org Mon Dec 05 16:50:08 2016 Received: (at 25112) by debbugs.gnu.org; 5 Dec 2016 21:50:08 +0000 Received: from localhost ([127.0.0.1]:57378 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cE19D-0003yO-UV for submit@debbugs.gnu.org; Mon, 05 Dec 2016 16:50:08 -0500 Received: from aserp1040.oracle.com ([141.146.126.69]:19477) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cE19C-0003xq-1X for 25112@debbugs.gnu.org; Mon, 05 Dec 2016 16:50:06 -0500 Received: from aserv0021.oracle.com (aserv0021.oracle.com [141.146.126.233]) by aserp1040.oracle.com (Sentrion-MTA-4.3.2/Sentrion-MTA-4.3.2) with ESMTP id uB5Lnx6j008580 (version=TLSv1 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Mon, 5 Dec 2016 21:50:00 GMT Received: from userv0122.oracle.com (userv0122.oracle.com [156.151.31.75]) by aserv0021.oracle.com (8.13.8/8.14.4) with ESMTP id uB5Lnx7V029624 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Mon, 5 Dec 2016 21:49:59 GMT Received: from abhmp0004.oracle.com (abhmp0004.oracle.com [141.146.116.10]) by userv0122.oracle.com (8.14.4/8.14.4) with ESMTP id uB5LnvwX023678; Mon, 5 Dec 2016 21:49:58 GMT MIME-Version: 1.0 Message-ID: <62e0bec4-0ffd-49f9-b8be-577c40882399@default> Date: Mon, 5 Dec 2016 13:49:56 -0800 (PST) From: Drew Adams To: Eli Zaretskii Subject: RE: bug#25112: 24.5; function to encode time from time string References: <<5b95d9b8-3281-40da-872d-1a98b8a3d1fa@default>> <<83vauyjr3g.fsf@gnu.org>> In-Reply-To: <<83vauyjr3g.fsf@gnu.org>> X-Priority: 3 X-Mailer: Oracle Beehive Extensions for Outlook 2.0.1.9.1 (1003210) [OL 12.0.6753.5000 (x86)] Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Source-IP: aserv0021.oracle.com [141.146.126.233] X-Spam-Score: -5.2 (-----) X-Debbugs-Envelope-To: 25112 Cc: 25112@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -5.2 (-----) > > Enhancement request: Please add a function that accepts a time > > string and a format spec (to interpret the time string), and > > returns a time value that represents the same time. >=20 > I believe you want either date-to-time or parse-time-string (the > former is just a thin wrapper around the latter). date-to-time is > described in the ELisp manual. Sheesh. Dunno how I missed `date-to-time' in the manual. I read the 3 nodes about dates & times, but clearly I didn't read them well enough. Maybe it would help to mention this direction of conversion after the second paragraph of node `Time of Day', with a cross-reference? And maybe the node named `Time Conversion' should mention something about conversion both directions between strings and times, with cross-references? Anyway, `date-to-time' does what I want (though it seems to give only a 2-element list, at least in the cases I've tried). Its name does NOT seem very good, though. Among other things, either a date or a time can be represented as either a list or a string - neither is inherently only one or the other. It might help to say something like: (current-time-string (date-to-time date-time-string)) =3D date-time-string and (date-to-time (current-time-string date-time-list)) =3D date-time-list Or if these are not always strictly true then at least point out that this is the general idea. E.g., (current-time-string (date-to-time "Sun Nov 27 16:38:38 2016")) =3D "Sun Nov 27 16:38:38 2016" (date-to-time (current-time-string '(22587 31886))) =3D (22587 31886) I will close this bug, in any case. Thx. From debbugs-submit-bounces@debbugs.gnu.org Mon Dec 05 17:03:09 2016 Received: (at control) by debbugs.gnu.org; 5 Dec 2016 22:03:09 +0000 Received: from localhost ([127.0.0.1]:57382 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cE1Lp-0004Jm-45 for submit@debbugs.gnu.org; Mon, 05 Dec 2016 17:03:09 -0500 Received: from aserp1040.oracle.com ([141.146.126.69]:27384) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cE1Ln-0004JM-49 for control@debbugs.gnu.org; Mon, 05 Dec 2016 17:03:07 -0500 Received: from aserv0021.oracle.com (aserv0021.oracle.com [141.146.126.233]) by aserp1040.oracle.com (Sentrion-MTA-4.3.2/Sentrion-MTA-4.3.2) with ESMTP id uB5M31ek025993 (version=TLSv1 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Mon, 5 Dec 2016 22:03:01 GMT Received: from aserv0121.oracle.com (aserv0121.oracle.com [141.146.126.235]) by aserv0021.oracle.com (8.13.8/8.14.4) with ESMTP id uB5M317t006481 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Mon, 5 Dec 2016 22:03:01 GMT Received: from abhmp0004.oracle.com (abhmp0004.oracle.com [141.146.116.10]) by aserv0121.oracle.com (8.13.8/8.13.8) with ESMTP id uB5M2tuY003959 for ; Mon, 5 Dec 2016 22:02:57 GMT MIME-Version: 1.0 Message-ID: <2f785225-10e2-45ce-bd25-a9b26fda4852@default> Date: Mon, 5 Dec 2016 14:02:54 -0800 (PST) From: Drew Adams To: control@debbugs.gnu.org Subject: close 25112 X-Priority: 3 X-Mailer: Oracle Beehive Extensions for Outlook 2.0.1.9.1 (1003210) [OL 12.0.6753.5000 (x86)] Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Source-IP: aserv0021.oracle.com [141.146.126.233] X-Spam-Score: -5.2 (-----) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -5.2 (-----) close 25112 thanks From unknown Tue Aug 19 22:00:57 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Tue, 03 Jan 2017 12:24:04 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator