From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: pjb@informatimago.com (Pascal J. Bourguignon) Newsgroups: gmane.emacs.help Subject: Re: Days between dates Date: Fri, 10 Oct 2008 21:42:09 +0200 Organization: Informatimago Message-ID: <87bpxs2q5q.fsf@hubble.informatimago.com> References: <1a48184e-c58c-4c42-8660-058f514418ed@n33g2000pri.googlegroups.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1223671282 27094 80.91.229.12 (10 Oct 2008 20:41:22 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 10 Oct 2008 20:41:22 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Fri Oct 10 22:42:20 2008 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1KoOo8-0006yy-0k for geh-help-gnu-emacs@m.gmane.org; Fri, 10 Oct 2008 22:41:56 +0200 Original-Received: from localhost ([127.0.0.1]:52969 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KoOn3-00068s-VR for geh-help-gnu-emacs@m.gmane.org; Fri, 10 Oct 2008 16:40:49 -0400 Original-Path: news.stanford.edu!headwall.stanford.edu!newshub.sdsu.edu!feeder.erje.net!proxad.net!feeder1-2.proxad.net!cleanfeed1-b.proxad.net!nnrp11-1.free.fr!not-for-mail Original-Newsgroups: gnu.emacs.help Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwAQMAAABtzGvEAAAABlBMVEUAAAD///+l2Z/dAAAA oElEQVR4nK3OsRHCMAwF0O8YQufUNIQRGIAja9CxSA55AxZgFO4coMgYrEDDQZWPIlNAjwq9 033pbOBPtbXuB6PKNBn5gZkhGa86Z4x2wE67O+06WxGD/HCOGR0deY3f9Ijwwt7rNGNf6Oac l/GuZTF1wFGKiYYHKSFAkjIo1b6sCYS1sVmFhhhahKQssRjRT90ITWUk6vvK3RsPGs+M1RuR mV+hO/VvFAAAAABJRU5ErkJggg== X-Accept-Language: fr, es, en X-Disabled: X-No-Archive: no User-Agent: Gnus/5.1008 (Gnus v5.10.8) Emacs/22.2 (gnu/linux) Cancel-Lock: sha1:DwQSqqR/3LR71YujA78GQH9WIIs= Original-Lines: 21 Original-NNTP-Posting-Date: 10 Oct 2008 21:42:09 MEST Original-NNTP-Posting-Host: 88.182.134.169 Original-X-Trace: 1223667729 news-4.free.fr 26530 88.182.134.169:49693 Original-X-Complaints-To: abuse@proxad.net Original-Xref: news.stanford.edu gnu.emacs.help:163338 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:58680 Archived-At: Chry Cheng writes: > How does one calculate the no. of days between two dates in Elisp? So > far, I have the following: > > (decode-time (time-subtract (date-to-time "...") (date-to-time > "..."))) > > But decode-time returns dates. I was wondering if there already is a > function somewhere unknown to me that would do this. I have a function named days-between in emacs-version "22.2.1" -- __Pascal Bourguignon__ http://www.informatimago.com/ PLEASE NOTE: Some quantum physics theories suggest that when the consumer is not directly observing this product, it may cease to exist or will exist only in a vague and undetermined state.