aboutsummaryrefslogtreecommitdiffstats
path: root/src/alloc.c
diff options
context:
space:
mode:
authorPaul Eggert2011-05-20 22:38:43 -0700
committerPaul Eggert2011-05-20 22:38:43 -0700
commit0ae6bdee0085b05028108325b0a4ce979eadb24e (patch)
tree51746679d14a133e355aeb2effe115db5dd692f5 /src/alloc.c
parentde883a701d8f0db9595c6c459fdff9e3bb20bc83 (diff)
downloademacs-0ae6bdee0085b05028108325b0a4ce979eadb24e.tar.gz
emacs-0ae6bdee0085b05028108325b0a4ce979eadb24e.zip
* data.c: Avoid integer truncation in expressions involving floats.
* data.c: Include <intprops.h>. (arith_driver): When there's an integer overflow in an expression involving floating point, convert the integers to floating point so that the resulting value does not suffer from catastrophic integer truncation. For example, on a 64-bit host (* 4 most-negative-fixnum 0.5) should yield about -4.6e+18, not zero. Do not rely on undefined behavior after integer overflow.
Diffstat (limited to 'src/alloc.c')
0 files changed, 0 insertions, 0 deletions