diff options
Diffstat (limited to 'Doc/library/functions.rst')
-rw-r--r-- | Doc/library/functions.rst | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/Doc/library/functions.rst b/Doc/library/functions.rst index 04fb95e..b94c434 100644 --- a/Doc/library/functions.rst +++ b/Doc/library/functions.rst @@ -583,11 +583,16 @@ are always available. They are listed here in alphabetical order. .. function:: hash(object) - Return the hash value of the object (if it has one). Hash values are integers. - They are used to quickly compare dictionary keys during a dictionary lookup. - Numeric values that compare equal have the same hash value (even if they are of - different types, as is the case for 1 and 1.0). + Return the hash value of the object (if it has one). Hash values are + integers. They are used to quickly compare dictionary keys during a + dictionary lookup. Numeric values that compare equal have the same hash + value (even if they are of different types, as is the case for 1 and 1.0). + .. note:: + + For object's with custom :meth:`__hash__` methods, note that :func:`hash` + truncates the return value based on the bit width of the host machine. + See :meth:`__hash__` for details. .. function:: help([object]) |