# HG changeset patch # User Edward M. Reingold # Date 783185434 0 # Node ID be6a59921f856c38693e50c2fc5a399d39901cdc # Parent b5fb08fb2cb33e8b621a97280906736c6ac4175e Fix regexps for diary marking to include TAB. diff -r b5fb08fb2cb3 -r be6a59921f85 lisp/=diary-lib.el --- a/lisp/=diary-lib.el Wed Oct 26 15:28:56 1994 +0000 +++ b/lisp/=diary-lib.el Wed Oct 26 15:30:34 1994 +0000 @@ -761,12 +761,12 @@ The recognized forms are XXXX or X:XX or XX:XX (military time), XXam or XXpm, and XX:XXam or XX:XXpm." (cond ((string-match;; Military time - "^ *\\([0-9]?[0-9]\\):?\\([0-9][0-9]\\)\\(\\>\\|[^ap]\\)" s) + "^[ \t]*\\([0-9]?[0-9]\\):?\\([0-9][0-9]\\)\\(\\>\\|[^ap]\\)" s) (+ (* 100 (string-to-int (substring s (match-beginning 1) (match-end 1)))) (string-to-int (substring s (match-beginning 2) (match-end 2))))) ((string-match;; Hour only XXam or XXpm - "^ *\\([0-9]?[0-9]\\)\\([ap]\\)m\\>" s) + "^[ \t]*\\([0-9]?[0-9]\\)\\([ap]\\)m\\>" s) (+ (* 100 (% (string-to-int (substring s (match-beginning 1) (match-end 1))) 12)) @@ -774,7 +774,7 @@ (substring s (match-beginning 2) (match-end 2))) 0 1200))) ((string-match;; Hour and minute XX:XXam or XX:XXpm - "^ *\\([0-9]?[0-9]\\):\\([0-9][0-9]\\)\\([ap]\\)m\\>" s) + "^[ \t]*\\([0-9]?[0-9]\\):\\([0-9][0-9]\\)\\([ap]\\)m\\>" s) (+ (* 100 (% (string-to-int (substring s (match-beginning 1) (match-end 1))) 12)) @@ -1322,7 +1322,7 @@ (defun diary-ordinal-suffix (n) "Ordinal suffix for N. (That is, `st', `nd', `rd', or `th', as appropriate.)" (if (or (memq (% n 100) '(11 12 13)) - (< 3 (% n 10))) + (< 3 (% n 10))) "th" (aref ["th" "st" "nd" "rd"] (% n 10))))