mirror of
https://github.com/python/cpython.git
synced 2025-08-03 16:39:00 +00:00
Issue #15535: Fix pickling of named tuples.
This commit is contained in:
parent
8e596a765c
commit
b98dcc1f53
4 changed files with 9 additions and 0 deletions
|
@ -281,6 +281,10 @@ class {typename}(tuple):
|
|||
'Return self as a plain tuple. Used by copy and pickle.'
|
||||
return tuple(self)
|
||||
|
||||
def __getstate__(self):
|
||||
'Exclude the OrderedDict from pickling'
|
||||
return None
|
||||
|
||||
{field_defs}
|
||||
'''
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue