diff options
author | Paul Eggert <eggert@cs.ucla.edu> | 2015-11-21 10:38:19 -0800 |
---|---|---|
committer | Paul Eggert <eggert@cs.ucla.edu> | 2015-11-21 10:44:04 -0800 |
commit | 8afaa1321f8088bfb877fe4b6676e8517adb0bb7 (patch) | |
tree | 7e865f4b42fc44ba38abf7d0188db0aa05096fbd /src/regex.c | |
parent | d696d62fea48096680d6d511a71c4df56d00a51f (diff) | |
download | emacs-8afaa1321f8088bfb877fe4b6676e8517adb0bb7.tar.gz emacs-8afaa1321f8088bfb877fe4b6676e8517adb0bb7.tar.bz2 emacs-8afaa1321f8088bfb877fe4b6676e8517adb0bb7.zip |
Add a few safety checks when ENABLE_CHECKING
This was motivated by the recent addition of module code,
which added some ENABLE_CHECKING-enabled checks that are
useful elsewhere too.
* src/alloc.c (compact_font_cache_entry):
* src/fns.c (sweep_weak_table):
* src/lread.c (oblookup):
Use gc_asize rather than doing it by hand.
* src/emacs-module.c (module_make_global_ref)
(module_free_global_ref, module_vec_size):
Omit assertions that lisp.h now checks.
* src/lisp.h (XFASTINT, ASIZE): In functional implementations,
check that the result is nonnegative. Use eassume, as this
info can help a bit when optimizing production code.
(XSYMBOL) [!USE_LSB_TAG]: Assert that argument is a symbol,
to be consistent with the USE_LSB_TAG case.
(gc_asize): New function, when ASIZE is needed in the gc.
(gc_aset): Use it.
(HASH_TABLE_P): Move definition up, so that it can be used ...
(XHASH_TABLE): ... here, to assert that the arg is a hash table.
Diffstat (limited to 'src/regex.c')
0 files changed, 0 insertions, 0 deletions