summaryrefslogtreecommitdiffstats
path: root/lisplib.c
diff options
context:
space:
mode:
authorKaz Kylheku <kaz@kylheku.com>2021-08-19 02:49:49 -0700
committerKaz Kylheku <kaz@kylheku.com>2021-08-19 02:49:49 -0700
commit46be04f43613e08af5015485ff19bb79af1d3feb (patch)
tree79c6dd55738c2c120b32f6958cba12d4789a506e /lisplib.c
parentca59be500904f84f5b138257cc152e1ec6764819 (diff)
downloadtxr-46be04f43613e08af5015485ff19bb79af1d3feb.tar.gz
txr-46be04f43613e08af5015485ff19bb79af1d3feb.tar.bz2
txr-46be04f43613e08af5015485ff19bb79af1d3feb.zip
hash: use unsigned, and operation.
* hash.c (struct hash): modulus and count change from cnum to ucnum. (hash_mark, hash_grow, copy_hash, do_weak_tables): Use ucnum local vars. (do_make_hash, make_similar_hash): Use c_unum to obtain modulus. (gethash_c, gethash_e): Use & masking operation to reduce hash value to table size. (remhash): Move sanity check before decrement since unsigned value can't go below zero. (clearhash): Use ucnum and c_unum. (hash_iter_peek): Use ucnum for chain count local. * hash.h (struct hash_iter): chain changes from cnum to ucnum.
Diffstat (limited to 'lisplib.c')
0 files changed, 0 insertions, 0 deletions