Tweak wording for dataclasses.replace (gh-117758)
This commit is contained in:
parent
a74f117dab
commit
e7cce2a9c6
@ -430,8 +430,8 @@ Module contents
|
|||||||
|
|
||||||
Creates a new object of the same type as ``obj``, replacing
|
Creates a new object of the same type as ``obj``, replacing
|
||||||
fields with values from ``changes``. If ``obj`` is not a Data
|
fields with values from ``changes``. If ``obj`` is not a Data
|
||||||
Class, raises :exc:`TypeError`. If values in ``changes`` do not
|
Class, raises :exc:`TypeError`. If keys in ``changes`` are not
|
||||||
specify fields, raises :exc:`TypeError`.
|
field names of the given dataclass, raises :exc:`TypeError`.
|
||||||
|
|
||||||
The newly returned object is created by calling the :meth:`~object.__init__`
|
The newly returned object is created by calling the :meth:`~object.__init__`
|
||||||
method of the dataclass. This ensures that
|
method of the dataclass. This ensures that
|
||||||
|
Loading…
x
Reference in New Issue
Block a user