https://github.com/python/cpython/commit/e7cce2a9c696250aff64a57b85182356367be041
commit: e7cce2a9c696250aff64a57b85182356367be041
branch: main
author: Gouvernathor <[email protected]>
committer: ericvsmith <[email protected]>
date: 2024-04-13T20:03:09-04:00
summary:
Tweak wording for dataclasses.replace (gh-117758)
files:
M Doc/library/dataclasses.rst
diff --git a/Doc/library/dataclasses.rst b/Doc/library/dataclasses.rst
index 61b2263339da71..0b479f0d569981 100644
--- a/Doc/library/dataclasses.rst
+++ b/Doc/library/dataclasses.rst
@@ -430,8 +430,8 @@ Module contents
Creates a new object of the same type as ``obj``, replacing
fields with values from ``changes``. If ``obj`` is not a Data
- Class, raises :exc:`TypeError`. If values in ``changes`` do not
- specify fields, raises :exc:`TypeError`.
+ Class, raises :exc:`TypeError`. If keys in ``changes`` are not
+ field names of the given dataclass, raises :exc:`TypeError`.
The newly returned object is created by calling the :meth:`~object.__init__`
method of the dataclass. This ensures that
_______________________________________________
Python-checkins mailing list -- [email protected]
To unsubscribe send an email to [email protected]
https://mail.python.org/mailman3/lists/python-checkins.python.org/
Member address: [email protected]