mirror of
git://git.sv.gnu.org/emacs.git
synced 2026-01-10 13:40:36 -08:00
(calendar-cursor-to-date): Fix to signal error when appropriate.
This commit is contained in:
parent
100aa77cf6
commit
1beddd9bb1
1 changed files with 6 additions and 6 deletions
|
|
@ -1962,12 +1962,12 @@ ERROR is t, otherwise just returns nil."
|
|||
(list month
|
||||
(string-to-int (buffer-substring (1+ (point)) (+ 4 (point))))
|
||||
year))
|
||||
(if (looking-at "\\*")
|
||||
(save-excursion
|
||||
(re-search-backward "[^*]")
|
||||
(if (looking-at ".\\*\\*")
|
||||
(list month starred-day year)
|
||||
(if error (error "Cursor is not on a date!"))))))))
|
||||
(if (and (looking-at "\\*")
|
||||
(save-excursion
|
||||
(re-search-backward "[^*]")
|
||||
(looking-at ".\\*\\*")))
|
||||
(list month starred-day year)
|
||||
(if error (error "Cursor is not on a date!"))))))
|
||||
|
||||
(defun calendar-cursor-to-nearest-date ()
|
||||
"Move the cursor to the closest date.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue