mirror of
git://git.sv.gnu.org/emacs.git
synced 2025-12-15 10:30:25 -08:00
Replace string-to-int' by string-to-number'.
This commit is contained in:
parent
cc211a0ff8
commit
216d380630
8 changed files with 47 additions and 34 deletions
|
|
@ -208,13 +208,13 @@ telling Microsoft that.")
|
|||
(cur-date (and exp (timezone-parse-date (current-time-string))))
|
||||
(exp-date (and exp (timezone-parse-date exp)))
|
||||
(cur-greg (and cur-date (timezone-absolute-from-gregorian
|
||||
(string-to-int (aref cur-date 1))
|
||||
(string-to-int (aref cur-date 2))
|
||||
(string-to-int (aref cur-date 0)))))
|
||||
(string-to-number (aref cur-date 1))
|
||||
(string-to-number (aref cur-date 2))
|
||||
(string-to-number (aref cur-date 0)))))
|
||||
(exp-greg (and exp (timezone-absolute-from-gregorian
|
||||
(string-to-int (aref exp-date 1))
|
||||
(string-to-int (aref exp-date 2))
|
||||
(string-to-int (aref exp-date 0)))))
|
||||
(string-to-number (aref exp-date 1))
|
||||
(string-to-number (aref exp-date 2))
|
||||
(string-to-number (aref exp-date 0)))))
|
||||
(diff-in-days (and exp (- cur-greg exp-greg)))
|
||||
)
|
||||
(cond
|
||||
|
|
@ -224,12 +224,12 @@ telling Microsoft that.")
|
|||
(t ; Expires sometime today, check times
|
||||
(let* ((cur-time (timezone-parse-time (aref cur-date 3)))
|
||||
(exp-time (timezone-parse-time (aref exp-date 3)))
|
||||
(cur-norm (+ (* 360 (string-to-int (aref cur-time 2)))
|
||||
(* 60 (string-to-int (aref cur-time 1)))
|
||||
(* 1 (string-to-int (aref cur-time 0)))))
|
||||
(exp-norm (+ (* 360 (string-to-int (aref exp-time 2)))
|
||||
(* 60 (string-to-int (aref exp-time 1)))
|
||||
(* 1 (string-to-int (aref exp-time 0))))))
|
||||
(cur-norm (+ (* 360 (string-to-number (aref cur-time 2)))
|
||||
(* 60 (string-to-number (aref cur-time 1)))
|
||||
(* 1 (string-to-number (aref cur-time 0)))))
|
||||
(exp-norm (+ (* 360 (string-to-number (aref exp-time 2)))
|
||||
(* 60 (string-to-number (aref exp-time 1)))
|
||||
(* 1 (string-to-number (aref exp-time 0))))))
|
||||
(> (- cur-norm exp-norm) 1))))))
|
||||
|
||||
;;;###autoload
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue