Commit e5f10c67 authored by Paul Eggert's avatar Paul Eggert

Pacify byte-compiler in calculator.el

* lisp/calculator.el (calculator-expt): Open-code cl-evenp to
pacify warning “the function ‘cl-evenp’ might not be defined”.
Problem reported by Juanma Barranquero in:
https://lists.gnu.org/r/emacs-devel/2019-11/msg00118.html
parent edec35aa
Pipeline #3941 failed with stage
in 57 minutes and 32 seconds
......@@ -1620,7 +1620,9 @@ To use this, apply a binary operator (evaluate it), then call this."
(condition-case nil
(expt x y)
(overflow-error
(if (or (natnump x) (cl-evenp y))
;; X and Y must be integers, as expt silently returns floating-point
;; infinity on floating-point overflow.
(if (or (natnump x) (zerop (logand x 1)))
1.0e+INF
-1.0e+INF))))
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment