diff options
author | Georg Brandl <georg@python.org> | 2013-05-12 11:09:11 +0200 |
---|---|---|
committer | Georg Brandl <georg@python.org> | 2013-05-12 11:09:11 +0200 |
commit | ce654f48aac8c060ee3188f597e4fb78b2839abb (patch) | |
tree | ac5d70691a8aea217dccd26f2072aa2a9353f99c /Lib/collections.py | |
parent | a6df938fefd5b51d85a45cf3f29f60ee7bb21edf (diff) | |
download | cpython-git-ce654f48aac8c060ee3188f597e4fb78b2839abb.tar.gz |
Issue #15535: Fix pickling of named tuples.
Diffstat (limited to 'Lib/collections.py')
-rw-r--r-- | Lib/collections.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/Lib/collections.py b/Lib/collections.py index eb2024352d..33aedd973a 100644 --- a/Lib/collections.py +++ b/Lib/collections.py @@ -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} ''' |