mirror of
https://github.com/python/cpython.git
synced 2025-11-02 11:08:57 +00:00
gh-110275: Named tuple's __replace__() now raises TypeError for invalid arguments (GH-110299)
This commit is contained in:
parent
da6760bdf5
commit
c74e9fb189
5 changed files with 9 additions and 7 deletions
|
|
@ -981,6 +981,10 @@ field names, the method and attribute names start with an underscore.
|
|||
|
||||
Named tuples are also supported by generic function :func:`copy.replace`.
|
||||
|
||||
.. versionchanged:: 3.13
|
||||
Raise :exc:`TypeError` instead of :exc:`ValueError` for invalid
|
||||
keyword arguments.
|
||||
|
||||
.. attribute:: somenamedtuple._fields
|
||||
|
||||
Tuple of strings listing the field names. Useful for introspection
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue