fix secondary hash-code for weak hashes

This commit is contained in:
Matthew Flatt 2011-12-02 12:11:52 -07:00
parent 67c3aa4b2d
commit 96330556e7
2 changed files with 2 additions and 1 deletions

View File

@ -2504,6 +2504,7 @@
(test (equal-hash-code ht) values (equal-hash-code ht2))
(test (equal-hash-code wht) values (equal-hash-code wht2))
(test (equal-secondary-hash-code ht) values (equal-secondary-hash-code ht2))
(test (equal-secondary-hash-code wht) values (equal-secondary-hash-code wht2))
(let ([ht (for/hash ([i (in-list l)])
(values (a i) (a (a i))))]

View File

@ -1759,7 +1759,7 @@ static uintptr_t equal_hash_key2(Scheme_Object *o, Hash_Info *hi)
if (key) {
k += equal_hash_key2((Scheme_Object *)bucket->val, hi);
k += equal_hash_key2((Scheme_Object *)key, hi);
old_depth = hi->depth;
hi->depth = old_depth;
}
}
}