mirror of
https://github.com/python/cpython.git
synced 2025-08-23 10:16:01 +00:00
gh-66143: Allow copying and pickling of CodecInfo object (GH-109235)
Co-authored-by: Robert Lehmann <mail@robertlehmann.de>
This commit is contained in:
parent
7d57288f6d
commit
3439cb0049
3 changed files with 75 additions and 0 deletions
|
@ -111,6 +111,9 @@ class CodecInfo(tuple):
|
|||
(self.__class__.__module__, self.__class__.__qualname__,
|
||||
self.name, id(self))
|
||||
|
||||
def __getnewargs__(self):
|
||||
return tuple(self)
|
||||
|
||||
class Codec:
|
||||
|
||||
""" Defines the interface for stateless encoders/decoders.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue