Don't special case named tuples. The default behavior is fine. (#1874)
This commit is contained in:
parent
31d814345e
commit
54a16d60ef
|
@ -150,8 +150,7 @@ implement ``__deconstruct__()`` and should consider redefining ``__match_args__`
|
|||
* ``__deconstruct__()``: should return a sequence which contains the parts of the deconstructed object.
|
||||
|
||||
.. note::
|
||||
``__match_args__`` will be automatically generated for dataclasses, as specified in PEP 634.
|
||||
``__match_args__`` and ``__deconstruct__`` will be automatically generated for named tuples.
|
||||
``__match_args__`` will be automatically generated for dataclasses and named tuples, as specified in PEP 634.
|
||||
|
||||
The pattern matching implementation is *not* required to check that ``__match_args__`` and ``__deconstruct__`` behave as specified.
|
||||
If the value of ``__match_args__`` or the result of ``__deconstruct__()`` is not as specified, then
|
||||
|
|
Loading…
Reference in New Issue