diff options
Diffstat (limited to 'Lib/pickle.py')
-rw-r--r-- | Lib/pickle.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/pickle.py b/Lib/pickle.py index c93352f..a028d9d 100644 --- a/Lib/pickle.py +++ b/Lib/pickle.py @@ -346,7 +346,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 |