projects
/
emacs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
6bd817e
)
* src/fns.c (hashfn_user_defined): Make sure we always return a fixnum.
author
Stefan Monnier
<monnier@iro.umontreal.ca>
Tue, 23 Jul 2019 12:29:21 +0000
(08:29 -0400)
committer
Stefan Monnier
<monnier@iro.umontreal.ca>
Tue, 23 Jul 2019 12:29:21 +0000
(08:29 -0400)
src/fns.c
patch
|
blob
|
history
diff --git
a/src/fns.c
b/src/fns.c
index d28d437df9c7d16dd41e5b9d895f9ff1b4ae94df..f4f3b95ac642e41a344af7e1194dc2158164f74c 100644
(file)
--- a/
src/fns.c
+++ b/
src/fns.c
@@
-4023,7
+4023,7
@@
hashfn_user_defined (Lisp_Object key, struct Lisp_Hash_Table *h)
{
Lisp_Object args[] = { h->test.user_hash_function, key };
Lisp_Object hash = hash_table_user_defined_call (ARRAYELTS (args), args, h);
- return
BIGNUMP (hash) ? make_fixnum (sxhash_bignum (XBIGNUM (hash))) : hash
;
+ return
FIXNUMP (hash) ? hash : make_fixnum (sxhash (hash, 0))
;
}
struct hash_table_test const