Commit 75762c68 authored by Glenn Morris's avatar Glenn Morris

(mark-diary-entries): Move some constant variables outside the

diary-date-forms loop.
parent ef473719
......@@ -3,6 +3,13 @@
* startup.el (command-line-1): Rename -internal-script back to
-scriptload (reverts previous change).
* calendar/cal-coptic.el (coptic-calendar-month-name-array):
(ethiopic-calendar-month-name-array, ethiopic-name): Add doc strings.
(coptic-prompt-for-date): Move definition before use.
* calendar/diary-lib.el (mark-diary-entries): Move some constant
variables outside the diary-date-forms loop.
* calendar/calendar.el (diary-file): Doc fix.
(calendar-buffer-list): Return buffers rather than strings (fixes
previous change).
......
......@@ -1094,6 +1094,16 @@ diary entries."
(setq mark-diary-entries-in-calendar nil)
(redraw-calendar))
(let ((marking-diary-entries t)
(dayname
(diary-name-pattern calendar-day-name-array
calendar-day-abbrev-array))
(monthname
(format "%s\\|\\*"
(diary-name-pattern calendar-month-name-array
calendar-month-abbrev-array)))
(month "[0-9]+\\|\\*")
(day "[0-9]+\\|\\*")
(year "[0-9]+\\|\\*")
file-glob-attrs marks)
(with-current-buffer (find-file-noselect (diary-check-diary-file) t)
(save-excursion
......@@ -1105,17 +1115,7 @@ diary entries."
(dolist (date-form diary-date-forms)
(if (eq (car date-form) 'backup)
(setq date-form (cdr date-form))) ; ignore 'backup directive
(let* ((dayname
(diary-name-pattern calendar-day-name-array
calendar-day-abbrev-array))
(monthname
(format "%s\\|\\*"
(diary-name-pattern calendar-month-name-array
calendar-month-abbrev-array)))
(month "[0-9]+\\|\\*")
(day "[0-9]+\\|\\*")
(year "[0-9]+\\|\\*")
(l (length date-form))
(let* ((l (length date-form))
(d-name-pos (- l (length (memq 'dayname date-form))))
(d-name-pos (if (/= l d-name-pos) (+ 1 d-name-pos)))
(m-name-pos (- l (length (memq 'monthname date-form))))
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment