%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /usr/local/share/emacs/27.2/lisp/calendar/
Upload File :
Create Path :
Current File : //usr/local/share/emacs/27.2/lisp/calendar/time-date.elc

;ELC
;;; Compiled
;;; in Emacs version 27.2
;;; with all optimizations.

;;; This file uses dynamic docstrings, first added in Emacs 19.29.

;;; This file does not contain utf-8 non-ASCII characters,
;;; and so can be loaded in Emacs versions earlier than 23.

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;


(byte-code "\300\301!\210\300\302!\207" [require cl-lib subr-x] 2)
#@649 Decode a time value and bind it according to VARLIST, then eval BODY.

The value of the last form in BODY is returned.

Each element of the list VARLIST is a list of the form
(HIGH-SYMBOL LOW-SYMBOL MICRO-SYMBOL [PICO-SYMBOL [TYPE-SYMBOL]] TIME-VALUE).
The time value TIME-VALUE is decoded and the result is bound to
the symbols HIGH-SYMBOL, LOW-SYMBOL and MICRO-SYMBOL.
The optional PICO-SYMBOL is bound to the picoseconds part.

The optional TYPE-SYMBOL is bound to the type of the time value.
Type 0 is the cons cell (HIGH . LOW), type 1 is the list (HIGH
LOW), type 2 is the list (HIGH LOW MICRO), and type 3 is the
list (HIGH LOW MICRO PICO).
(defalias 'with-decoded-time-value '(macro . #[(varlist &rest body) "\203:\211A\242\211\211A\242	\211A\242	\211A\242	G\306X?\205)	\211A\242	G\307=?\2057	\211A\2427	@8\310\311!9\312\3139\3148\315BBD9\316\3179D\320\3219\322BB\3239\324BBED\3259D\312\326\327\330\3319\332BBED\333\334\335\336\3319\337BBDD\340\3369\341BBD\257\342BBD\3439DFD\n\3449DD\f\257
\205\243
C7\205\2537C#\345\3469D\347\350\3449DE\3459\347\350\f\3519DE
\203\363\345\3529D\313\350
\3539DE7\205\3367\354B\"\313\350
\355BB7\205\3567\356B\"F\202\3717\205\371\357E\313\350\f\360BB
\205
\361B7\2057\362B#FE\313\3509\f\363BBBB
\205%
\364B7\205.7\365B#F\366:BBF.\207\347:B\207" [varlist elt high low micro pico 2 1 make-symbol "time" let* append or ((current-time)) cond integerp list ash (-16) logand (65535) floatp usec * 1000000 mod (1) (ps (round (* 1000000 (mod usec 1)))) (us (floor usec)) lo floor (65536) hi (65536) ((if (eq ps 1000000) (progn (setq ps 0) (setq us (1+ us)) (if (eq us 1000000) (progn (setq us 0) (setq lo (1+ lo)) (if (eq lo 65536) (progn (setq lo 0) (setq hi (1+ hi)))))))) (list hi lo us ps)) t pop if consp progn setq car cdr cadr (3) (0) (2) (setq type 2) (0) (0) (1) (0) (0) (0) with-decoded-time-value type time-value gensym body] 18 (#$ . 476)]))
(byte-code "\300\301\302\303#\304\301\305\306#\207" [function-put with-decoded-time-value lisp-indent-function 1 put edebug-form-spec ((&rest (symbolp symbolp symbolp &or [symbolp symbolp form] [symbolp form] form)) body)] 5)
#@331 Encode HIGH, LOW, MICRO, and PICO into a time value of type TYPE.
Type 0 is the cons cell (HIGH . LOW), type 1 is the list (HIGH LOW),
type 2 is (HIGH LOW MICRO), and type 3 is (HIGH LOW MICRO PICO).

For backward compatibility, if only four arguments are given,
it is assumed that PICO was omitted and should be treated as zero.
(defalias 'encode-time-value #[(high low micro pico &optional type) "\204	\305\306\267\202!\nB\207\nD\207\n\fE\207\n\f	F\207\307\207" [type pico high low micro 0 #s(hash-table size 4 test eq rehash-size 1.5 rehash-threshold 0.8125 purecopy t data (0 14 1 18 2 22 3 27)) nil] 4 (#$ . 2667)])
(byte-code "\300\301\302\303#\210\300\304\302\303#\210\305\306\307\"\210\305\310\311\"\207" [make-obsolete encode-time-value nil "25.1" with-decoded-time-value autoload parse-time-string "parse-time" timezone-make-date-arpa-standard "timezone"] 4)
#@196 Parse a string DATE that represents a date-time and return a time value.
DATE should be in one of the forms recognized by `parse-time-string'.
If DATE lacks timezone information, GMT is assumed.
(defalias 'date-to-time #[(date) "\3031\304\305!!0\207\306	\n\232\203\307	@	A\"\202A\3101,\304\305\311!!!0\202A\211\n\232\203<\307	@	A\"\202@\312\313\")*\207" [date err overflow-error (error) encode-time parse-time-string (error "Specified time is not representable") signal (error) timezone-make-date-arpa-standard error "Invalid date: %s"] 5 (#$ . 3554)])
(byte-code "\300\301\302\"\210\300\303\304\"\207" [defalias time-to-seconds float-time seconds-to-time time-convert] 3)
#@33 Convert DAYS into a time value.
(defalias 'days-to-time #[(days) "\302\303_!\250\203	A:\203	A\304\241\210	)\207" [days time time-convert 86400 nil] 3 (#$ . 4248)])
#@95 Return the time elapsed since TIME.
TIME should be either a time value or a date-time string.
(defalias 'time-since #[(time) ";\203	\301!\302\303\"\207" [time date-to-time time-subtract nil] 3 (#$ . 4425)])
(byte-code "\300\301\302\303#\210\304\301\302\305#\207" [defalias subtract-time time-subtract nil make-obsolete "26.1"] 4)
#@165 Return the absolute date of DATE, a date-time string.
The absolute date is the number of days elapsed since the imaginary
Gregorian date Sunday, December 31, 1 BC.
(defalias 'date-to-day #[(date) "\301\302!!\207" [date time-to-days date-to-time] 3 (#$ . 4767)])
#@97 Return the number of days between DATE1 and DATE2.
DATE1 and DATE2 should be date-time strings.
(defalias 'days-between #[(date1 date2) "\302!\302	!Z\207" [date1 date2 date-to-day] 3 (#$ . 5036)])
#@34 Return t if YEAR is a leap year.
(defalias 'date-leap-year-p #[(year) "\301\246\302U\203\303\246\302U?\206\304\246\302U\207" [year 4 0 100 400] 2 (#$ . 5240)])
#@78 Return the day number within the year corresponding to the decoded time TIM.
(defalias 'time-date--day-in-year #[(tim) "\3058\3068\3078\n\310	S_\\	\311V\203,\f\312\305	_\\\313\245Z\314!\203,\fT\f,\207" [tim month day year day-of-year 4 3 5 31 2 23 10 date-leap-year-p] 4 (#$ . 5413)])
#@62 Return the day number within the year corresponding to TIME.
(defalias 'time-to-day-in-year #[(time) "\301\302!!\207" [time time-date--day-in-year decode-time] 3 (#$ . 5716)])
#@166 The absolute date corresponding to TIME, a time value.
The absolute date is the number of days elapsed since the imaginary
Gregorian date Sunday, December 31, 1 BC.
(defalias 'time-to-days #[(time) "\303!\304	8\305\306	!\307\nS_\nS\310\245\nS\311\245[\nS\312\245%*\207" [time tim year decode-time 5 + time-date--day-in-year 365 4 100 400] 7 (#$ . 5900)])
#@81 Return the number of days represented by TIME.
Returns a floating point number.
(defalias 'time-to-number-of-days #[(time) "\301!\302\245\207" [time float-time 86400] 2 (#$ . 6264)])
#@126 Parse a string DATE that represents a date-time and return a time value.
If DATE is malformed, return a time value of zeros.
(defalias 'safe-date-to-time #[(date) "\3011	\302!0\207\210\303\207" [date (error) date-to-time (0 0)] 2 (#$ . 6455)])
#@789 Use format control STRING to format the number SECONDS.
The valid format specifiers are:
%y is the number of (365-day) years.
%d is the number of days.
%h is the number of hours.
%m is the number of minutes.
%s is the number of seconds.
%z is a non-printing control flag (see below).
%% is a literal "%".

Upper-case specifiers are followed by the unit-name (e.g. "years").
Lower-case specifiers return only the unit.

"%" may be followed by a number specifying a width, with an
optional leading "." for zero-padding.  For example, "%.3Y" will
return something of the form "001 year".

The "%z" specifier does not print anything.  When it is used, specifiers
must be given in order of decreasing size.  To the left of "%z", nothing
is output until the first non-zero unit is encountered.
(defalias 'format-seconds #[(string seconds) "\306\307\310\311\211\211\211\211\211\211\211\211\211$%&'()*\312\313+*#\203\212\306\225*\314\315+\"\211'\316\230\204!\317'\227)\"\211&\204O\320\321'\"\210\317'\227%\"\203_\320\322'\"\210&@\323\230\203m\310$\202\200
\204\200\324&8\f\205}\n\fV\n&%B%\202!$\203\227
\203\227\320\325!\210\326,\327\",)\311-\211.\203;.@\211-@'-A@\324-8\312\330\331'\"+\"\2032'\323\230\203\345\332\333\334\335+\206\333\306\225\306\224^\"#+\2022\336,\n\",	\n_Z,\204	\306U?\205\306\224\337\330\316\314\315+\"\340Q	\314\324+\"'\230\203\334\202*\330\341	\315U\203(\334\202)\342##\310\211+$+.A\211.\204\251.\332\343\316+#\207" [zeropos num unit name prev larger 0 (("y" "year" 31536000) ("d" "day" 86400) ("h" "hour" 3600) ("m" "minute" 60) ("s" "second" 1) ("z")) t nil string-match "%\\.?[0-9]*\\(.\\)" match-string 1 "%" assoc error "Bad format specifier: `%s'" "Multiple instances of specifier: `%s'" "z" 2 "Units are not in decreasing order of size" time-convert integer format "%%\\(\\.?[0-9]+\\)?\\(%s\\)" replace-regexp-in-string "%z" "" substring floor replace-match "d%s" " %s%s" "s" "%%" zeroflag usedunits match spec case-fold-search units start string seconds u --dolist-tail--] 14 (#$ . 6708)])
#@54 Formatting used by the function `seconds-to-string'.
(defvar seconds-to-string (byte-code "\300\301\302E\303\304\300E\305\306\307E\310\311\312E\313\314\315E\316\317\320\321\322\323#E\257\207" [1 "ms" 0.001 100 "s" 6000 "m" 60.0 108000 "h" 3600.0 34560000 "d" 86400.0 nil "y" * 365.25 24 3600] 11) (#$ . 8822))
#@57 Convert the time interval in seconds to a short string.
(defalias 'seconds-to-string #[(delay) "\304V\203
\305\301[!P\207\304U\203\306\207	\307\211A\242\211@\203+\n@X\204\310\311\nAA@\245\"\nA@P*\207" [delay seconds-to-string here sts 0 "-" "0s" nil format "%.2f"] 4 (#$ . 9139)])
#@38 The number of days in MONTH in YEAR.
(defalias 'date-days-in-month #[(year month) "\302U\203\303	!\203\304\207\305\207\306>\203\307\207\310\207" [month year 2 date-leap-year-p 29 28 (1 3 5 7 8 10 12) 31 30] 2 (#$ . 9442)])
#@153 Convert a YEAR/ORDINAL to the equivalent `decoded-time' structure.
ORDINAL is the number of days since the start of the year, with
January 1st being 1.
(defalias 'date-ordinal-to-time #[(year ordinal) "\303	\304\n\"V\203	\304\n\"ZT\202\305\211\211	\n\305\211\211\257	)\207" [month ordinal year 1 date-days-in-month nil] 9 (#$ . 9680)])
#@895 Add DELTA to TIME, both of which are `decoded-time' structures.
TIME should represent a time, while DELTA should have non-nil
entries only for the values that should be altered.

For instance, if you want to "add two months" to TIME, then
leave all other fields but the month field in DELTA nil, and make
the month field 2.  The values in DELTA can be negative.

If applying a month/year delta leaves the time spec invalid, it
is decreased to be valid ("add one month" to January 31st 2019
will yield a result of February 28th 2019 and "add one year" to
February 29th 2020 will result in February 28th 2021).

Fields are added in a most to least significant order, so if the
adjustment described above happens, it happens before adding
days, hours, minutes or seconds.

When changing the time bits in TIME (i.e., second/minute/hour),
changes in daylight saving time are not taken into account.
(defalias 'decoded-time-add #[(time delta) "\306!\307\310\n8\203\310\233\211\211@\310\n8\\\240\210)\311\n8\203C\3118\311\n8\\\311\233\211\312\f\313\"\240\210)\310\233\211\211@\f\313\245\\\240\210*\314\233\211\315\3108\3118\"\3148^\240\210)\314\n8\211\203\204\316V\317!\316V\203\203\320\"\210S\211\202o*)\321\n@\206\214\316\322\"\323	\321\324\325\n8\206\232\316\326_\nA@\206\243\316\327_\330\n8\206\254\316#	A\"\"\331	\"\210*\207" [time seconds delta #1=#:c new #2=#:c copy-sequence nil 5 4 mod 12 3 date-days-in-month 0 abs decoded-time--alter-day time-convert t time-add + 2 3600 60 8 decoded-time--alter-second #3=#:c #4=#:c days increase] 9 (#$ . 10034)])
#@46 Increase or decrease the month in TIME by 1.
(defalias 'decoded-time--alter-month #[(time increase) "\203+\306	\233\211\211@T\240\210)\306	8\307V\205S\306	\233\211\310\240\210)\311	\233\211\211@T\240)\207\306	\233\211\211@S\240\210)\306	8\312U\205S\306	\233\211\307\240\210)\311	\233\211\f\211@S\240)\207" [increase time #1=#:c #2=#:c #3=#:c #4=#:c 4 12 1 5 0 #5=#:c #6=#:c] 3 (#$ . 11644)])
#@44 Increase or decrease the day in TIME by 1.
(defalias 'decoded-time--alter-day #[(time increase) "\203,\306	\233\211\211@T\240\210)\306	8\307\310	8\311	8\"V\205S\306	\233\211\312\240\210)\313	\314\"\207\306	\233\211\211@S\240\210)\306	8\315U\205S\313	\316\"\210\306	\233\211\307\310	8\311	8\"\240)\207" [increase time #1=#:c #2=#:c #3=#:c #4=#:c 3 date-days-in-month 5 4 1 decoded-time--alter-month t 0 nil] 6 (#$ . 12053)])
#@39 Increase the time in TIME by SECONDS.
(defalias 'decoded-time--alter-second #[(time seconds) "\306@\206\307\310\"\211A\311	\306\312\3138\206\307_\314A@\206!\307_\\\n\"\"\306\311\f\"\310\"\211A\306\315\"\316
\307\"\203O\317\320\"\210\311
\"\202:\316
\"\204e\317\310\"\210\321
\"\202O\306
\322\"\211\311\306\314\246\"\321
\306\"\"\"\240\210)A\211\314\245\314\246\240\210)AA\211\312\245\240.\207" [time time-sec time-hz old seconds new time-convert 0 t time-add 3600 2 60 86400 time-less-p decoded-time--alter-day nil time-subtract integer new-hz secsperday sec #1=#:v #2=#:c #3=#:c] 9 (#$ . 12491)])
#@130 Return a `decoded-time' structure with only the keywords given filled out.

(fn &key SECOND MINUTE HOUR DAY MONTH YEAR DST ZONE)
(defalias 'make-decoded-time #[(&rest #1=#:--cl-rest--) "\306\307\"A@\306\310\"A@\306\311\"A@\306\312\"A@\306\313\"A@\306\314\"A@\306\315\"A@\306\316\"A@\203n@\317>\203UAA\211\202@\320>A@\203d\321\211\202@\322\323@\"\210\202>)	\n\f
\321\257	.\207" [#1# second minute hour day month 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)" year dst zone #2=#:--cl-keys--] 10 (#$ . 13153)])
#@155 Set any nil values in `decoded-time' TIME to default values.
The default value is based on January 1st, 1970 at midnight.

TIME is modified and returned.
(defalias 'decoded-time-set-defaults #[(time &optional default-zone) "@\204\f\211\306\240\210)A@\204A\211\306\240\210)\3078\204)AA\211\306\240\210)\3108\2048\310\233\211\311\240\210)\3128\204G\312\233\211\311\240\210)\3138\204W\313\233\211\306\240\210)\3148\204m\3158\204m\315\233\211\316\240\210)\3148\204\202\203\202\314\233\211\306\240\210)\207" [time #1=#:v #2=#:c #3=#:c #4=#:c #5=#:c 0 2 3 1 4 5 8 7 -1 #6=#:c #7=#:c default-zone #8=#:c] 3 (#$ . 13919)])
(provide 'time-date)

Zerion Mini Shell 1.0