[issue5169] Default hash not equal to id on AMD Sempron
Jesús Cea Avión
report at bugs.python.org
Fri Feb 6 23:09:22 CET 2009
Jesús Cea Avión <jcea at jcea.es> added the comment:
The issue is trivially reproductible in any 32 bits platform, simply
allocating objects until you go up the 2GB mark.
Since __hash__() wants to take advantage of every bit in a 32 bit
platform, and we don't have unsigned integers in python, I vote for
"invalid" too.
There is no promise of "id(obj)==hash(obj)": you can overload
"__hash__()" anytime, and that is already done for strings, integers,
tuples, etc.
The speed advantage is interesting, though.
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue5169>
_______________________________________
More information about the Python-bugs-list
mailing list