Commit eba62f7a authored by Jay Belanger's avatar Jay Belanger
Browse files

calc-ext.el (math-group-float): Have the number of digits being

grouped depend on the radix (Bug#6189).
parent 9beab9ce
2010-05-16 Jay Belanger <jay.p.belanger@gmail.com>
* calc/calc-ext.el (math-group-float): Have the number of digits
being grouped depend on the radix (Bug#6189).
2010-05-15 Ken Raeburn <raeburn@raeburn.org>
* version.el (emacs-copyright, emacs-version): Don't define here,
......
......@@ -3469,7 +3469,8 @@ If X is not an error form, return 1."
(defun math-group-float (str) ; [X X]
(let* ((pt (or (string-match "[^0-9a-zA-Z]" str) (length str)))
(g (if (integerp calc-group-digits) (math-abs calc-group-digits) 3))
(g (if (integerp calc-group-digits) (math-abs calc-group-digits)
(if (memq calc-number-radix '(2 16)) 4 3)))
(i pt))
(if (and (integerp calc-group-digits) (< calc-group-digits 0))
(while (< (setq i (+ (1+ i) g)) (length str))
......
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