Avoid undefined behavior in signed left shift.
authorPaul Eggert <eggert@cs.ucla.edu>
Mon, 28 Apr 2014 01:29:44 +0000 (18:29 -0700)
committerPaul Eggert <eggert@cs.ucla.edu>
Mon, 28 Apr 2014 01:29:44 +0000 (18:29 -0700)
commit6ab1b16c54b63d1c4217b6fcea026400029fcc72
treee3fef3d5e3f4436b2bc59b1006afc98075da06f0
parent196bfaecb0caffcdbb699694139a97148e90e227
Avoid undefined behavior in signed left shift.

This ports to GCC 4.9.0 with -fsanitize=undefined.
* alloc.c (bool_vector_fill, SETMARKBIT, UNSETMARKBIT):
* data.c (Fash):
* regex.c (extract_number):
* lisp.h (make_number, XINT):
Do not shift a 1 bit left into a sign bit.
* alloc.c (struct cons_block, struct float_block): Use unsigned,
not int, for gcmarkbits.  All uses changed.
src/ChangeLog
src/alloc.c
src/data.c
src/lisp.h
src/regex.c