summaryrefslogtreecommitdiff
path: root/lisp/emacs-lisp/seq.el
diff options
context:
space:
mode:
authorMattias Engdegård <mattiase@acm.org>2020-10-10 18:02:49 +0200
committerMattias Engdegård <mattiase@acm.org>2020-10-13 11:29:01 +0200
commitcf407958886e46881216a510efebb8bc029de50c (patch)
tree2f67e4b672f10355ad941a39abd58b6c523a3683 /lisp/emacs-lisp/seq.el
parentadd1314195b193f04164cebe558d7a185b61de96 (diff)
downloademacs-cf407958886e46881216a510efebb8bc029de50c.tar.gz
emacs-cf407958886e46881216a510efebb8bc029de50c.tar.bz2
emacs-cf407958886e46881216a510efebb8bc029de50c.zip
Calc: allow infinite binary word size (bug#43764)
Setting the word size ("b w") to 0 removes the word size clipping for all bit operations (effectively as if a word size of -∞ had been set). Rotation is disallowed; logical and arithmetic shifts behave identically. After a suggestion by Vincent Belaïche. * lisp/calc/calc-bin.el (calc-word-size, math-binary-arg) (math-binary-modulo-args, calcFunc-lsh, calcFunc-ash, calcFunc-rot) (math-clip, math-format-twos-complement): Allow a word size of 0, meaning -∞. * test/lisp/calc/calc-tests.el (calc-tests--not, calc-tests--and, calc-tests--or, calc-tests--xor) (calc-tests--diff): New functions. (calc-tests--clip, calc-tests--rot, calc-shift-binary): Extend to cover word size 0. (calc-bit-ops): New test. * doc/misc/calc.texi (Binary Functions): Update manual. * etc/NEWS: Announce the change.
Diffstat (limited to 'lisp/emacs-lisp/seq.el')
0 files changed, 0 insertions, 0 deletions