]> git.eshelyaron.com Git - emacs.git/commitdiff
Broaden format-seconds to Lisp timestamps
authorPaul Eggert <eggert@cs.ucla.edu>
Sat, 17 Aug 2019 01:10:14 +0000 (18:10 -0700)
committerPaul Eggert <eggert@cs.ucla.edu>
Sat, 17 Aug 2019 01:12:24 +0000 (18:12 -0700)
* lisp/calendar/time-date.el (format-seconds):
Accept any Lisp timestamp instead of insisting on a number.

lisp/calendar/time-date.el

index c22f441420138086cb2b37cd3c659b41cecdbdcd..fa5e886869a1e3d56c58b3c6a808a25dd77e7115 100644 (file)
@@ -306,7 +306,7 @@ is output until the first non-zero unit is encountered."
         (push match usedunits)))
     (and zeroflag larger
          (error "Units are not in decreasing order of size"))
-    (setq seconds (floor seconds))
+    (setq seconds (time-convert seconds 'integer))
     (dolist (u units)
       (setq spec (car u)
             name (cadr u)