diff options
author | Nick Coghlan <ncoghlan@gmail.com> | 2012-05-20 11:22:27 (GMT) |
---|---|---|
committer | Nick Coghlan <ncoghlan@gmail.com> | 2012-05-20 11:22:27 (GMT) |
commit | 305acf2fffaf4653819268adca81d99a6551e072 (patch) | |
tree | ba1a8388e0825df221e04231933e44b27454ead6 /Doc | |
parent | dc9b2555a8752d70f1e4a6d3f5cc0ce8046b3d00 (diff) | |
download | cpython-305acf2fffaf4653819268adca81d99a6551e072.zip cpython-305acf2fffaf4653819268adca81d99a6551e072.tar.gz cpython-305acf2fffaf4653819268adca81d99a6551e072.tar.bz2 |
Remove an incorrect implementation detail
Diffstat (limited to 'Doc')
-rw-r--r-- | Doc/reference/datamodel.rst | 5 |
1 files changed, 0 insertions, 5 deletions
diff --git a/Doc/reference/datamodel.rst b/Doc/reference/datamodel.rst index 643cabc..fa60723 100644 --- a/Doc/reference/datamodel.rst +++ b/Doc/reference/datamodel.rst @@ -1262,16 +1262,11 @@ Basic customization immutable (if the object's hash value changes, it will be in the wrong hash bucket). - User-defined classes have :meth:`__eq__` and :meth:`__hash__` methods by default; with them, all objects compare unequal (except with themselves) and ``x.__hash__()`` returns an appropriate value such that ``x == y`` implies both that ``x is y`` and ``hash(x) == hash(y)``. - .. impl-detail:: - - CPython uses ``hash(id(x))`` as the default hash for class instances. - Classes which inherit a :meth:`__hash__` method from a parent class but change the meaning of :meth:`__eq__` such that the hash value returned is no longer appropriate (e.g. by switching to a value-based concept of equality |