diff options
Diffstat (limited to 'lisp/gnus/gnus-util.el')
-rw-r--r-- | lisp/gnus/gnus-util.el | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/lisp/gnus/gnus-util.el b/lisp/gnus/gnus-util.el index bd870a2f1c8..3766b3bd59d 100644 --- a/lisp/gnus/gnus-util.el +++ b/lisp/gnus/gnus-util.el @@ -285,12 +285,14 @@ Symbols are also allowed; their print names are used instead." (and (= (car fdate) (car date)) (> (nth 1 fdate) (nth 1 date)))))) -(defun gnus-float-time (&optional time) - "Convert time value TIME to a floating point number. +(eval-and-compile + (if (and (fboundp 'float-time) + (subrp (symbol-function 'float-time))) + (defalias 'gnus-float-time 'float-time) + (defun gnus-float-time (&optional time) + "Convert time value TIME to a floating point number. TIME defaults to the current time." - (if (featurep 'xemacs) - (time-to-seconds (or time (current-time))) - (float-time time))) + (with-no-warnings (time-to-seconds (or time (current-time))))))) ;;; Keymap macros. |