Mercurial > emacs
changeset 81719:38726b7738d9
(math-add-bignum): Replace number by constant.
author | Jay Belanger <jay.p.belanger@gmail.com> |
---|---|
date | Fri, 06 Jul 2007 03:56:12 +0000 |
parents | 85dcb1dc6a9c |
children | 72f269f335c9 |
files | lisp/calc/calc.el |
diffstat | 1 files changed, 2 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/lisp/calc/calc.el Fri Jul 06 02:41:18 2007 +0000 +++ b/lisp/calc/calc.el Fri Jul 06 03:56:12 2007 +0000 @@ -2780,7 +2780,7 @@ (progn (setcar aa (1+ sum)) (setq carry nil)) - (setcar aa (+ sum -999))) + (setcar aa (- sum (1- math-bignum-digit-size)))) (if (< (setq sum (+ (car aa) (car b))) math-bignum-digit-size) (setcar aa sum) (setcar aa (- sum math-bignum-digit-size)) @@ -2790,7 +2790,7 @@ (if carry (if b (nconc a (math-add-bignum b '(1))) - (while (eq (car aa) 999) + (while (eq (car aa) (1- math-bignum-digit-size)) (setcar aa 0) (setq aa (cdr aa))) (if aa