;ELC   
;;; Compiled
;;; in Emacs version 28.2
;;; with all optimizations.



(byte-code "\300\301!\210\300\302!\207" [require time-date cl-lib] 2)
#@16 

(fn REGEXPS)
(defalias 'iso8601--concat-regexps #[257 "\300\301\302#\207" [mapconcat #[257 "\300\301\302\303#\304Q\207" ["\\(?:" string-replace "(" "(?:" "\\)"] 6 "\n\n(fn REGEXP)"] "\\|"] 5 (#$ . 154)])
(defconst iso8601--year-match "\\([+-]?[0-9][0-9][0-9][0-9]\\)")
(defconst iso8601--full-date-match "\\([+-]?[0-9][0-9][0-9][0-9]\\)-?\\([0-9][0-9]\\)-?\\([0-9][0-9]\\)")
(defconst iso8601--without-day-match "\\([+-]?[0-9][0-9][0-9][0-9]\\)-\\([0-9][0-9]\\)")
(defconst iso8601--outdated-date-match "--\\([0-9][0-9]\\)-?\\([0-9][0-9]\\)")
(defconst iso8601--outdated-reduced-precision-date-match "---?\\([0-9][0-9]\\)")
(defconst iso8601--week-date-match "\\([+-]?[0-9][0-9][0-9][0-9]\\)-?W\\([0-9][0-9]\\)-?\\([0-9]\\)?")
(defconst iso8601--ordinal-date-match "\\([+-]?[0-9][0-9][0-9][0-9]\\)-?\\([0-9][0-9][0-9]\\)")
(defconst iso8601--date-match (byte-code "\306	\n\f\257!\207" [iso8601--year-match iso8601--full-date-match iso8601--without-day-match iso8601--outdated-date-match iso8601--outdated-reduced-precision-date-match iso8601--week-date-match iso8601--concat-regexps iso8601--ordinal-date-match] 8))
(defconst iso8601--time-match "\\([0-9][0-9]\\):?\\([0-9][0-9]\\)?:?\\([0-9][0-9]\\)?[.,]?\\([0-9]*\\)")
(defconst iso8601--zone-match "\\(Z\\|\\([+-]\\)\\([0-9][0-9]\\):?\\([0-9][0-9]\\)?\\)")
(defconst iso8601--full-time-match (byte-code "\302\303\304\305#\306	\307\260\207" [iso8601--time-match iso8601--zone-match "\\(" string-replace "(" "(?:" "\\)\\(" "\\)?"] 5))
(defconst iso8601--combined-match (byte-code "\303\304\305\306\307	#\310\n\311\260\207" [iso8601--date-match iso8601--time-match iso8601--zone-match "\\(" "\\)\\(?:T\\(" string-replace "(" "(?:" "\\)\\(" "\\)?\\)?"] 7))
(defconst iso8601--duration-full-match "P\\([0-9]+Y\\)?\\([0-9]+M\\)?\\([0-9]+D\\)?\\(T\\([0-9]+H\\)?\\([0-9]+M\\)?\\([0-9]+S\\)?\\)?")
(defconst iso8601--duration-week-match "P\\([0-9]+\\)W")
(defconst iso8601--duration-combined-match (concat "P" iso8601--combined-match))
(defconst iso8601--duration-match (byte-code "\303	\nE!\207" [iso8601--duration-full-match iso8601--duration-week-match iso8601--duration-combined-match iso8601--concat-regexps] 4))
#@358 Parse an ISO 8601 date/time string and return a `decode-time' structure.

The ISO 8601 date/time strings look like "2008-03-02T13:47:30",
but shorter, incomplete strings like "2008-03-02" are valid, as
well as variants like "2008W32" (week number) and
"2008-234" (ordinal day number).

See `decode-time' for the meaning of FORM.

(fn STRING &optional FORM)
(defalias 'iso8601-parse #[513 "\300!\204 \301\302\"\207\303\304\"\303\305\"\303\306\"\307!\203< \310\"AA\211\3058\240\266A\211A@\240\266@\240\266\203T \311\233\211\312!\313_\240\266\314\233\211\315\240\266\207" [iso8601-valid-p signal wrong-type-argument match-string 1 2 3 iso8601-parse-date iso8601-parse-time 8 iso8601-parse-zone 60 7 nil] 11 (#$ . 2338)])
#@82 Parse STRING (in ISO 8601 format) and return a `decode-time' value.

(fn STRING)
(defalias 'iso8601-parse-date #[257 "\306\"\203 \307\310\311!\"\207\306	\"\203, \307\310\311\312\313\"!\314\312\315\"\316\312\317\"&\207\306\n\"\203@ \307\310\311!\314\312\315\"$\207\306\"\203U \307\314\312\313\"\316\312\315\"$\207\306\f\"\203\365 \311!\311\312\315\"!\312\317\"\205r \311\312\317\"!\320\321\307\310\314\313\316\322&!!\3238\262\211\324U\203\217 \325\202\220 \211\317\\\325_\206\232 \324\\[\\\211\313W\203\273 S\262\211\326!\203\264 \327\202\265 \330\\\262\202\340 \211\326!\203\307 \327\202\310 \330V\203\340 \211\326!\203\330 \327\202\331 \330Z\262T\262\331\"\307\310\314\3228\316\3178&\207\306\"\203\311\312\313\"!\311\312\315\"!\331\"\307\310\314\3228\316\3178&\207\306\332\"\203,\307\314\311\312\313\"!\"\207\306\333\"\203=\307\316\311\312\313\"!\"\207\334\335\"\207" [iso8601--year-match iso8601--full-date-match iso8601--without-day-match iso8601--outdated-date-match iso8601--week-date-match iso8601--ordinal-date-match iso8601--match iso8601--decoded-time :year string-to-number match-string 1 :month 2 :day 3 decode-time iso8601--encode-time 4 6 0 7 date-leap-year-p 366 365 date-ordinal-to-time "--\\([0-9][0-9]\\)" "---\\([0-9][0-9]\\)" signal wrong-type-argument] 16 (#$ . 3088)])
#@236 Parse STRING, which should be an ISO 8601 time string.
The return value will be a `decode-time' structure with just the
hour/minute/seconds/zone fields filled in.

See `decode-time' for the meaning of FORM.

(fn STRING &optional FORM)
(defalias 'iso8601-parse-time #[513 "\302\"\204\f \303\304\"\207\305\306\"\305\307\"\302	\"\204  \303\304\"\207\310\305\306\"!\305\307\"\2053 \310\305\307\"!\305\311\"\205A \310\305\311\"!\305\312\"\313\211\203c \314\315\316#\262\317\320\"\203c \310!\262G\262\203\233 \321=\203\233 \203\204 \322\323\"_\\\322\323\"B\262\202\233 \203\221 \324\325\"\262\202\233 \203\233 \324\325\"\262\326\327\330\206\246 \320\331	\206\255 \320\332\205\271 \325\333!_&\207" [iso8601--full-time-match iso8601--time-match iso8601--match signal wrong-type-argument match-string 1 2 string-to-number 3 4 nil replace-regexp-in-string "0+\\'" "" length> 0 t expt 10 iso8601--decimalize 60 iso8601--decoded-time :hour :minute :second :zone iso8601-parse-zone] 21 (#$ . 4459)])
#@22 

(fn FRACTION BASE)
(defalias 'iso8601--decimalize #[514 "\300\301!\302\303\304\305\303\"!T\"\245_!\207" [round float expt 10 truncate log] 11 (#$ . 5500)])
#@97 Parse STRING, which should be an ISO 8601 time zone.
Return the number of minutes.

(fn STRING)
(defalias 'iso8601-parse-zone #[257 "\301\"\204\f \302\303\"\207\304\305\"\203? \306\304\307\"!\304\310\"\205& \306\304\310\"!\304\305\"\311\232\2033 \312\2024 \313\314_\206< \315\\_\207\315\207" [iso8601--zone-match iso8601--match signal wrong-type-argument match-string 2 string-to-number 3 4 "-" -1 1 60 0] 6 (#$ . 5668)])
#@69 Say whether STRING is a valid ISO 8601 representation.

(fn STRING)
(defalias 'iso8601-valid-p #[257 "\301\"\207" [iso8601--combined-match iso8601--match] 4 (#$ . 6106)])
#@69 Parse ISO 8601 durations on the form P3Y6M4DT12H30M5S.

(fn STRING)
(defalias 'iso8601-parse-duration #[257 "\303\"\203P \304\305\"G\306V\203P \307\310\304\311\"\206 \305\312\304\306\"\206% \305\313\304\314\"\206/ \305\315\304\316\n\"\2069 \305\317\304\320\f\"\206C \305\321\304\322\"\206M \305&\f\207\303	\"\203d \323\304\311\"!\307\313\322_\"\207\303\n\"\203r \324\311\325O!\207\326\327\"\207" [iso8601--duration-full-match iso8601--duration-week-match iso8601--duration-combined-match iso8601--match match-string 0 2 iso8601--decoded-time :year 1 :month :day 3 :hour 5 :minute 6 :second 7 string-to-number iso8601-parse nil signal wrong-type-argument] 16 (#$ . 6285)])
#@40 Parse ISO 8601 intervals.

(fn STRING)
(defalias 'iso8601-parse-interval #[257 "\300\301\"\302\211\211G\303U\204 \304\305\"\210\202| \306\307@\"\2037 \310A@!\2037 \311@!\262\312A@!\262\202| \306\307A@\"\203W \310@!\203W \311A@!\262\312@!\262\202| \310@!\203v \310A@!\203v \312@!\262\312A@!\262\202| \304\305\"\210\204\206 \313\"\262\204\223 \313\314\315\"\"\262\206\256 \316\317\320!\320!\"\3218\206\254 \322\323#E\207" [split-string "/" nil 2 signal wrong-type-argument string-match "\\`P" iso8601-valid-p iso8601-parse-duration iso8601-parse decoded-time-add mapcar #[257 "\211\247\203 \211[\207\207" [] 2 "\n\n(fn ELEM)"] decode-time time-subtract iso8601--encode-time 8 0 integer] 12 (#$ . 6982)])
#@22 

(fn REGEXP STRING)
(defalias 'iso8601--match #[514 "\300\301\302Q\"\207" [string-match "\\`" "\\'"] 6 (#$ . 7733)])
#@31 

(fn ELEM &optional DEFAULT)
(defalias 'iso8601--value #[513 ";\203	 \300!\207\206 \211\207" [string-to-number] 4 (#$ . 7859)])
#@56 

(fn &key SECOND MINUTE HOUR DAY MONTH YEAR DST ZONE)
(defalias 'iso8601--decoded-time #[128 "\300\301\"A@\300\302\"A@\300\303\"A@\300\304\"A@\300\305\"A@\300\306\"A@\300\307\"A@\300\310\"A@\211\203` \211@\311>\203H \211AA\262\2025 \312\n>A@\203W \313\262\2025 \314\315@\"\210\2025 \210\316!\316!\316!\316!\316!\316!\313\204\204 \203\211 \202\212 \317\257	\207" [plist-member :second :minute :hour :day :month :year :dst :zone (:second :minute :hour :day :month :year :dst :zone :allow-other-keys) :allow-other-keys nil error "Keyword argument %s not one of (:second :minute :hour :day :month :year :dst :zone)" iso8601--value -1] 18 (#$ . 7998)])
#@64 Like `encode-time', but fill in nil values in TIME.

(fn TIME)
(defalias 'iso8601--encode-time #[257 "\300\301\302!!!\207" [encode-time decoded-time-set-defaults copy-sequence] 5 (#$ . 8690)])
(provide 'iso8601)
