8000 Apply feedback · python/cpython@44ee0eb · GitHub
[go: up one dir, main page]

Skip to content

Commit 44ee0eb

Browse files
committed
Apply feedback
1 parent b69e1c2 commit 44ee0eb

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

Doc/library/dataclasses.rst

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -121,8 +121,10 @@ Module contents
121121
:meth:`!__le__`, :meth:`!__gt__`, or :meth:`!__ge__`, then
122122
:exc:`TypeError` is raised.
123123

124-
- *unsafe_hash*: If false (the default), a :meth:`~object.__hash__` method
125-
is generated according to how *eq* and *frozen* are set.
124+
- *unsafe_hash*: If true, force ``dataclasses`` to create a
125+
:meth:`~object.__hash__` method, even when it may not be safe to do so.
126+
Otherwise, generate a :meth:`~object.__hash__` method according to how
127+
*eq* and *frozen* are set. The default value is ``False``.
126128

127129
:meth:`!__hash__` is used by built-in :meth:`hash()`, and when objects are
128130
added to hashed collections such as dictionaries and sets. Having a

0 commit comments

Comments
 (0)
0