From: Glenn Morris Date: Sun, 27 Apr 2008 01:27:47 +0000 (+0000) Subject: (calculator-expt): Modify previous change to just use the expanded cl X-Git-Tag: emacs-pretest-23.0.90~6013 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=cba1a4bdc3d235144eddab1fc6e49b30f08cf924;p=emacs.git (calculator-expt): Modify previous change to just use the expanded cl definition of oddp. --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 55794b99016..11b7537bcd6 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,7 @@ +2008-04-27 Glenn Morris + + * calculator.el (calculator-expt): Replace cl function `oddp'. + 2008-04-27 Johan Bockgård * emacs-lisp/bytecomp.el (byte-compile-find-cl-functions): diff --git a/lisp/calculator.el b/lisp/calculator.el index be2fba355d8..030947b9f79 100644 --- a/lisp/calculator.el +++ b/lisp/calculator.el @@ -5,7 +5,7 @@ ;; Author: Eli Barzilay ;; Keywords: tools, convenience -;; Time-stamp: +;; Time-stamp: ;; This file is part of GNU Emacs. @@ -1795,18 +1795,18 @@ To use this, apply a binary operator (evaluate it), then call this." ;; For small x, the range error comes from large y. 0.0) ((and (> x 0.0) (< y 0.0)) - ;; For large positive x and negative y, the range error + ;; For large positive x and negative y, the range error ;; comes from large negative y. 0.0) ((and (> x 0.0) (> y 0.0)) - ;; For large positive x and positive y, the range error + ;; For large positive x and positive y, the range error ;; comes from large y. 1.0e+INF) ;; For the rest, x must be large and negative. ;; The range errors come from large integer y. ((< y 0.0) 0.0) - ((not (zerop (% (truncate y) 2))) + ((eq (logand (truncate y) 1) 1) ; expansion of cl `oddp' ;; If y is odd -1.0e+INF) (t