Function: todo-diary-expired-matcher

todo-diary-expired-matcher is a byte-compiled function defined in todo-mode.el.gz.

Signature

(todo-diary-expired-matcher LIM)

Documentation

Search for expired diary item date within LIM for font-locking.

Source Code

;; Defined in /usr/src/emacs/lisp/calendar/todo-mode.el.gz
(defun todo-diary-expired-matcher (lim)
  "Search for expired diary item date within LIM for font-locking."
  (when (re-search-forward (concat "^\\(?:"
				   (regexp-quote diary-nonmarking-symbol)
				   "\\)?\\(?1:" todo-date-pattern "\\) \\(?2:"
				   diary-time-regexp "\\)?")
                           lim t)
    (let* ((date (match-string-no-properties 1))
           (time (match-string-no-properties 2))
	   ;; Function days-between requires a non-empty time string.
           (date-time (concat date " " (or time "00:00"))))
      (or (and (not (string-match ".+day\\|\\*" date))
	       (< (days-between date-time (current-time-string)) 0))
	  (todo-diary-expired-matcher lim)))))