[docs] [issue13707] Clarify hash() constancy period

Terry J. Reedy report at bugs.python.org
Wed Jan 4 03:38:50 CET 2012

Terry J. Reedy <tjreedy at udel.edu> added the comment:

Martin, I do not understand. The default hash is based on id (as is default equality comparison), not value. Are you OK with hash values changing if the 'value' changes? My understanding is that changing hash values for objects in sets and dicts is bad, which is why mutable builtins with value-based equality do not have hash values.

title: Clarify hash() lifetime -> Clarify hash() constancy period

Python tracker <report at bugs.python.org>

More information about the docs mailing list