+2008-04-16 Glenn Morris <rgm@gnu.org>
+
+ * calendar/diary-lib.el (diary-remind): Don't clobber `date' passed
+ by diary-sexp-entry.
+
2008-04-16 Markus Triska <markus.triska@gmx.at>
* proced.el (proced-command-alist): Add support for darwin.
Marking of reminders is independent of whether the entry itself is a marking
or nonmarking; if optional parameter MARKING is non-nil then the reminders are
marked on the calendar."
- (let ((diary-entry (eval sexp))
- date)
+ ;; `date' has a value at this point, from diary-sexp-entry.
+ (let ((diary-entry (eval sexp)))
(cond
;; Diary entry applies on date.
((and diary-entry
((and (integerp days)
(not diary-entry) ; diary entry does not apply to date
(or (not diary-marking-entries-flag) marking))
- (setq date (calendar-gregorian-from-absolute
- (+ (calendar-absolute-from-gregorian date) days)))
- (when (setq diary-entry (eval sexp)) ; re-evaluate with adjusted date
- ;; Discard any mark portion from diary-anniversary, etc.
- (if (consp diary-entry) (setq diary-entry (cdr diary-entry)))
- (mapconcat 'eval diary-remind-message "")))
+ ;; Adjust date, and re-evaluate.
+ (let ((date (calendar-gregorian-from-absolute
+ (+ (calendar-absolute-from-gregorian date) days))))
+ (when (setq diary-entry (eval sexp))
+ ;; Discard any mark portion from diary-anniversary, etc.
+ (if (consp diary-entry) (setq diary-entry (cdr diary-entry)))
+ (mapconcat 'eval diary-remind-message ""))))
;; Diary entry may apply to one of a list of days before date.
((and (listp days) days)
(or (diary-remind sexp (car days) marking)