diff options
| author | Lars Ingebrigtsen | 2019-09-29 13:03:08 +0200 |
|---|---|---|
| committer | Lars Ingebrigtsen | 2019-09-29 13:03:08 +0200 |
| commit | 96636a8e1f5e91edb8ac4e88e0723beb7c71e160 (patch) | |
| tree | 3be5fc1ad04ca795351944dc0518189f607ba227 | |
| parent | 46eb6df45358f413847ceb882898b2326f7584c8 (diff) | |
| download | emacs-96636a8e1f5e91edb8ac4e88e0723beb7c71e160.tar.gz emacs-96636a8e1f5e91edb8ac4e88e0723beb7c71e160.zip | |
Fix up iso8601 time match regexp
* lisp/calendar/iso8601.el (iso8601--time-match): The fraction
mark can be either . or , and there can be arbitrarily many digits
in the fraction.
| -rw-r--r-- | lisp/calendar/iso8601.el | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lisp/calendar/iso8601.el b/lisp/calendar/iso8601.el index 0f42c824e32..f8949914f78 100644 --- a/lisp/calendar/iso8601.el +++ b/lisp/calendar/iso8601.el | |||
| @@ -83,7 +83,7 @@ | |||
| 83 | iso8601--ordinal-date-match))) | 83 | iso8601--ordinal-date-match))) |
| 84 | 84 | ||
| 85 | (defconst iso8601--time-match | 85 | (defconst iso8601--time-match |
| 86 | "\\([0-9][0-9]\\):?\\([0-9][0-9]\\)?:?\\([0-9][0-9]\\)?\\.?\\([0-9][0-9][0-9]\\)?") | 86 | "\\([0-9][0-9]\\):?\\([0-9][0-9]\\)?:?\\([0-9][0-9]\\)?[.,]?\\([0-9]+\\)?") |
| 87 | 87 | ||
| 88 | (defconst iso8601--zone-match | 88 | (defconst iso8601--zone-match |
| 89 | "\\(Z\\|\\([-+]\\)\\([0-9][0-9]\\):?\\([0-9][0-9]\\)?\\)") | 89 | "\\(Z\\|\\([-+]\\)\\([0-9][0-9]\\):?\\([0-9][0-9]\\)?\\)") |
| @@ -232,7 +232,7 @@ well as variants like \"2008W32\" (week number) and | |||
| 232 | (string-to-number (match-string 3 time)))) | 232 | (string-to-number (match-string 3 time)))) |
| 233 | ;; Hm... | 233 | ;; Hm... |
| 234 | (_millisecond (and (match-string 4 time) | 234 | (_millisecond (and (match-string 4 time) |
| 235 | (string-to-number (match-string 4 time))))) | 235 | (string-to-number (match-string 4 time))))) |
| 236 | (iso8601--decoded-time :hour hour | 236 | (iso8601--decoded-time :hour hour |
| 237 | :minute (or minute 0) | 237 | :minute (or minute 0) |
| 238 | :second (or second 0) | 238 | :second (or second 0) |