Commit 10f494b0 authored by Antoine Pitrou's avatar Antoine Pitrou

Fix whitespace

parent 060c717c
...@@ -4525,7 +4525,7 @@ class MiscTests(unittest.TestCase): ...@@ -4525,7 +4525,7 @@ class MiscTests(unittest.TestCase):
class PicklingTests(unittest.TestCase): class PicklingTests(unittest.TestCase):
def _check_reduce(self, proto, obj, args=(), kwargs={}, state=None, def _check_reduce(self, proto, obj, args=(), kwargs={}, state=None,
listitems=None, dictitems=None): listitems=None, dictitems=None):
if proto >= 4: if proto >= 4:
reduce_value = obj.__reduce_ex__(proto) reduce_value = obj.__reduce_ex__(proto)
...@@ -4559,7 +4559,7 @@ class PicklingTests(unittest.TestCase): ...@@ -4559,7 +4559,7 @@ class PicklingTests(unittest.TestCase):
base_type = type(obj).__base__ base_type = type(obj).__base__
reduce_value = (copyreg._reconstructor, reduce_value = (copyreg._reconstructor,
(type(obj), (type(obj),
base_type, base_type,
None if base_type is object else base_type(obj))) None if base_type is object else base_type(obj)))
if state is not None: if state is not None:
reduce_value += (state,) reduce_value += (state,)
...@@ -4774,7 +4774,7 @@ class PicklingTests(unittest.TestCase): ...@@ -4774,7 +4774,7 @@ class PicklingTests(unittest.TestCase):
def __getstate__(self): def __getstate__(self):
state = getattr(self, '__dict__', {}).copy() state = getattr(self, '__dict__', {}).copy()
for cls in type(self).__mro__: for cls in type(self).__mro__:
for slot in cls.__dict__.get('__slots__', ()): for slot in cls.__dict__.get('__slots__', ()):
try: try:
state[slot] = getattr(self, slot) state[slot] = getattr(self, slot)
except AttributeError: except AttributeError:
......
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