mirror of
https://github.com/python/cpython
synced 2024-07-21 02:05:18 +00:00
Make 'bin' argument trigger DeprecationWarning
This commit is contained in:
parent
cbbee6fed5
commit
dc54f2be3f
|
@ -199,7 +199,7 @@ def __init__(self, file, protocol=None, bin=None):
|
|||
raise ValueError, "can't specify both 'protocol' and 'bin'"
|
||||
if bin is not None:
|
||||
warnings.warn("The 'bin' argument to Pickler() is deprecated",
|
||||
PendingDeprecationWarning)
|
||||
DeprecationWarning)
|
||||
protocol = bin
|
||||
if protocol is None:
|
||||
protocol = 0
|
||||
|
|
Loading…
Reference in a new issue