From: Jay Belanger Date: Sun, 8 Jul 2007 00:18:06 +0000 (+0000) Subject: (math-bignum-logb-digit-size,math-bignum-digit-power-of-two): Evaluate X-Git-Tag: emacs-pretest-23.0.90~12009 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=4346200eb93682e0dda0149e71ea3ff462c0f397;p=emacs.git (math-bignum-logb-digit-size,math-bignum-digit-power-of-two): Evaluate when compiled. --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index aa6f87d2088..ebce356719f 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -3,6 +3,9 @@ * calc/calc.el (math-read-number-simple): Remove leading 0s. (math-bignum-digit-length): Change to optimal value. + * calc/calc-bin.el (math-bignum-logb-digit-size) + (math-bignum-digit-power-of-two): Evaluate when compiled. + * calc/calc-comb.el (math-small-factorial-table) (math-init-random-base,math-prime-test): Remove unnecessary calls to `math-read-number-simple'. diff --git a/lisp/calc/calc-bin.el b/lisp/calc/calc-bin.el index 8f3c9468d88..fa8ba118c8c 100644 --- a/lisp/calc/calc-bin.el +++ b/lisp/calc/calc-bin.el @@ -34,13 +34,13 @@ ;;; Some useful numbers (defconst math-bignum-logb-digit-size - (logb math-bignum-digit-size) + (eval-when-compile (logb math-bignum-digit-size)) "The logb of the size of a bignum digit. This is the largest value of B such that 2^B is less than the size of a Calc bignum digit.") (defconst math-bignum-digit-power-of-two - (expt 2 math-bignum-logb-digit-size) + (eval-when-compile (expt 2 math-bignum-logb-digit-size)) "The largest power of 2 less than the size of a Calc bignum digit.") ;;; b-prefix binary commands.