Mercurial > hg > xemacs-beta
diff tests/automated/hash-table-tests.el @ 4398:479443c0f95a
Have list hashes depend on the order of the contents, as is the case for vectors.
src/ChangeLog addition:
2008-01-16 Aidan Kehoe <kehoea@parhasard.net>
* elhash.c (internal_hash):
Make short lists with the same contents in a different order hash
distinctly. Gives better performance for things like three-element
lists describing colours. Thank you Sebastian Freundt!
tests/ChangeLog addition:
2008-01-16 Aidan Kehoe <kehoea@parhasard.net>
* automated/hash-table-tests.el:
Assert that two short lists with the same contents in distinct
orders hash differently.
author | Aidan Kehoe <kehoea@parhasard.net> |
---|---|
date | Wed, 16 Jan 2008 15:20:51 +0100 |
parents | db7c7e251153 |
children | 189fb67ca31a |
line wrap: on
line diff
--- a/tests/automated/hash-table-tests.el Wed Jan 16 00:19:59 2008 +0100 +++ b/tests/automated/hash-table-tests.el Wed Jan 16 15:20:51 2008 +0100 @@ -281,3 +281,4 @@ ;;; Test sxhash (Assert (= (sxhash "foo") (sxhash "foo"))) (Assert (= (sxhash '(1 2 3)) (sxhash '(1 2 3)))) +(Assert (/= (sxhash '(1 2 3)) (sxhash '(3 2 1))))