]> git.eshelyaron.com Git - emacs.git/commitdiff
(calendar-time-zone-daylight-rules): Simplify Persian conditionals.
authorGlenn Morris <rgm@gnu.org>
Tue, 23 Jun 2009 07:30:25 +0000 (07:30 +0000)
committerGlenn Morris <rgm@gnu.org>
Tue, 23 Jun 2009 07:30:25 +0000 (07:30 +0000)
lisp/ChangeLog
lisp/calendar/cal-dst.el

index 820aa6fc7647f55f5b8d77a113ab3d6b07abfad7..ae119c8848a734bd66ea8c6b68f840b475b80317 100644 (file)
@@ -1,5 +1,8 @@
 2009-06-23  Glenn Morris  <rgm@gnu.org>
 
+       * calendar/cal-dst.el (calendar-time-zone-daylight-rules):
+       Simplify Persian conditionals.
+
        * calc/calc-graph.el (calc-graph-plot): Avoid assignment to free
        variable `filename'.
 
index 0bcb61b4d42968f256c321be39be67d5dc90290f..b7d9b05228d2a308193670cb8f245788d52a5ff9 100644 (file)
@@ -212,12 +212,12 @@ The result has the proper form for `calendar-daylight-savings-starts'."
              rlist)
            ;; 01-01 and 07-01 for this year's Persian calendar.
            ;; FIXME what does the Persian calendar have to do with this?
-           (if (and (= m 3) (<= 20 d) (<= d 21))
-               '((calendar-gregorian-from-absolute
-                  (calendar-persian-to-absolute `(1 1 ,(- year 621))))))
-           (if (and (= m 9) (<= 22 d) (<= d 23))
-               '((calendar-gregorian-from-absolute
-                  (calendar-persian-to-absolute `(7 1 ,(- year 621))))))))
+           (and (= m 3) (memq d '(20 21))
+                '((calendar-gregorian-from-absolute
+                   (calendar-persian-to-absolute `(1 1 ,(- year 621))))))
+           (and (= m 9) (memq d '(22 23))
+                '((calendar-gregorian-from-absolute
+                   (calendar-persian-to-absolute `(7 1 ,(- year 621))))))))
          (prevday-sec (- -1 utc-diff)) ; last sec of previous local day
          (year (1+ y))
          new-rules)