From: Glenn Morris Date: Tue, 23 Jun 2009 07:30:25 +0000 (+0000) Subject: (calendar-time-zone-daylight-rules): Simplify Persian conditionals. X-Git-Tag: emacs-pretest-23.1.90~2444 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=84cb770dc98fddc1165b2a8aade90c33c97175be;p=emacs.git (calendar-time-zone-daylight-rules): Simplify Persian conditionals. --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 820aa6fc764..ae119c8848a 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,8 @@ 2009-06-23 Glenn Morris + * 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'. diff --git a/lisp/calendar/cal-dst.el b/lisp/calendar/cal-dst.el index 0bcb61b4d42..b7d9b05228d 100644 --- a/lisp/calendar/cal-dst.el +++ b/lisp/calendar/cal-dst.el @@ -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)