]> git.eshelyaron.com Git - emacs.git/commitdiff
(timezone-make-date-arpa-standard): Autoload.
authorDave Love <fx@gnu.org>
Fri, 10 Nov 2000 18:00:36 +0000 (18:00 +0000)
committerDave Love <fx@gnu.org>
Fri, 10 Nov 2000 18:00:36 +0000 (18:00 +0000)
(date-to-time): Use it.

lisp/gnus/time-date.el

index ba7f81a1ed1d01b37edb55639264f80992b3384a..3bfb9a454d04565e42f0e557b1c9988ad96b4e23 100644 (file)
 
 (require 'parse-time)
 
+(autoload 'timezone-make-date-arpa-standard "timezone")
+
 ;;;###autoload
 (defun date-to-time (date)
   "Convert DATE into time."
   (condition-case ()
-      (apply 'encode-time (parse-time-string date))
+      (apply 'encode-time
+            (parse-time-string
+             ;; `parse-time-string' isn't sufficiently general or
+             ;; robust.  It fails to grok some of the formats that
+             ;; timzeone does (e.g. dodgy post-2000 stuff from some
+             ;; Elms) and either fails or returns bogus values.  Lars
+             ;; reverted this change, but that loses non-trivially
+             ;; often for me.  -- fx
+             (timezone-make-date-arpa-standard date)))
     (error (error "Invalid date: %s" date))))
 
 (defun time-to-seconds (time)