Kaydet (Commit) 211b3cdb authored tarafından Brett Cannon's avatar Brett Cannon

Remove use of callable() from pickle to silence warnings under -3.

üst d13e4ba4
......@@ -351,7 +351,7 @@ class Pickler:
raise PicklingError("args from reduce() should be a tuple")
# Assert that func is callable
if not callable(func):
if not hasattr(func, '__call__'):
raise PicklingError("func from reduce should be callable")
save = self.save
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment