]> git.eshelyaron.com Git - emacs.git/commitdiff
Simplify math-get-calendar-tzinfo
authorPaul Eggert <eggert@cs.ucla.edu>
Wed, 10 Jul 2019 06:18:13 +0000 (23:18 -0700)
committerPaul Eggert <eggert@cs.ucla.edu>
Wed, 10 Jul 2019 06:18:36 +0000 (23:18 -0700)
* lisp/calc/calc-forms.el (calendar-current-time-zone-cache):
Remove defvar.
(math-get-calendar-tzinfo): Simplify and do not reach
into caldst’s cache.

lisp/calc/calc-forms.el

index 8faeb0a9decacc047b2347550407bc8ec0321b2e..eb1a8248cdfb1dceb31616611f4fa168aaa46808 100644 (file)
@@ -1472,9 +1472,6 @@ as measured in the integer number of days before December 31, 1 BC (Gregorian)."
 
 (defvar var-TimeZone nil)
 
-;; From cal-dst
-(defvar calendar-current-time-zone-cache)
-
 (defvar math-calendar-tzinfo
   nil
   "Information about the timezone, retrieved from the calendar.")
@@ -1487,9 +1484,7 @@ second, the number of seconds offset for daylight savings."
   (if math-calendar-tzinfo
       math-calendar-tzinfo
     (require 'cal-dst)
-    (let ((tzinfo (progn
-                    (calendar-current-time-zone)
-                    calendar-current-time-zone-cache)))
+    (let ((tzinfo (calendar-current-time-zone)))
       (setq math-calendar-tzinfo
             (list (* 60 (- (nth 0 tzinfo)))
                   (* 60 (nth 1 tzinfo)))))))