summaryrefslogtreecommitdiff
path: root/test/lisp/emacs-lisp/cl-macs-tests.el
diff options
context:
space:
mode:
authorPaul Eggert <eggert@cs.ucla.edu>2018-06-25 12:21:40 -0700
committerPaul Eggert <eggert@cs.ucla.edu>2018-06-25 12:23:08 -0700
commitd0e2a341dd9a9a365fd311748df024ecb25b70ec (patch)
treeaa5b4e9f33777155349c3aacefece4d25199b887 /test/lisp/emacs-lisp/cl-macs-tests.el
parent27a21970f6faa9baf42823f731b7842b075e86eb (diff)
downloademacs-d0e2a341dd9a9a365fd311748df024ecb25b70ec.tar.gz
emacs-d0e2a341dd9a9a365fd311748df024ecb25b70ec.tar.bz2
emacs-d0e2a341dd9a9a365fd311748df024ecb25b70ec.zip
(format "%d" F) now truncates floating F
Problem reported by Paul Pogonyshev (Bug#31938). * src/editfns.c: Include math.h, for trunc. (styled_format): For %d, truncate floating-point numbers and convert -0 to 0, going back to how Emacs 26 did things. * doc/lispref/strings.texi (Formatting Strings): Document behavior of %o, %d, %x, %X on floating-point numbers. * src/floatfns.c (trunc) [!HAVE_TRUNC]: Rename from emacs_trunc and make it an extern function, so that editfns.c can use it. All callers changed. * test/src/editfns-tests.el (format-%d-float): New test.
Diffstat (limited to 'test/lisp/emacs-lisp/cl-macs-tests.el')
0 files changed, 0 insertions, 0 deletions