diff options
author | Paul Eggert <eggert@cs.ucla.edu> | 2021-12-16 09:40:21 -0800 |
---|---|---|
committer | Paul Eggert <eggert@cs.ucla.edu> | 2021-12-16 11:17:25 -0800 |
commit | 3e6c69de9d1ae99ebb71eb2ed04bdb9ee42cbb80 (patch) | |
tree | 594605924f2174df09d481f3a2e73891706ca236 /lisp/calendar | |
parent | 34e3ad5ae449f4801af09d1df89d57350d0dc579 (diff) | |
download | emacs-3e6c69de9d1ae99ebb71eb2ed04bdb9ee42cbb80.tar.gz emacs-3e6c69de9d1ae99ebb71eb2ed04bdb9ee42cbb80.tar.bz2 emacs-3e6c69de9d1ae99ebb71eb2ed04bdb9ee42cbb80.zip |
Fix icalendar time zone parsing glitch
* lisp/calendar/icalendar.el (icalendar--decode-isodatetime):
Use pcase instead of cl-case, as cl-macs might not be loaded.
Otherwise, a build complains “calendar/icalendar.el:618:57:
Warning: ‘90’ is a malformed function” and some
icalendar--decode-isodatetime tests fail. This fixes a bug
introduced in 2021-11-21T08:18:57Z!dick.r.chiang@gmail.com.
Diffstat (limited to 'lisp/calendar')
-rw-r--r-- | lisp/calendar/icalendar.el | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lisp/calendar/icalendar.el b/lisp/calendar/icalendar.el index 7a483d40627..15778ea14bc 100644 --- a/lisp/calendar/icalendar.el +++ b/lisp/calendar/icalendar.el @@ -645,10 +645,10 @@ FIXME: multiple comma-separated values should be allowed!" (setq second (read (substring isodatetimestring 13 15)))) ;; FIXME: Support subseconds. (when (> (length isodatetimestring) 15) - (cl-case (aref isodatetimestring 15) + (pcase (aref isodatetimestring 15) (?Z (setq source-zone t)) - ((?- ?+) + ((or ?- ?+) (setq source-zone (concat "UTC" (substring isodatetimestring 15)))))) ;; shift if necessary |