Commit 9c7dac3b authored by Stefan Behnel's avatar Stefan Behnel

improve comments

parent aa748415
...@@ -1519,13 +1519,13 @@ class EarlyReplaceBuiltinCalls(Visitor.EnvTransform): ...@@ -1519,13 +1519,13 @@ class EarlyReplaceBuiltinCalls(Visitor.EnvTransform):
def _handle_simple_function_all(self, node, pos_args): def _handle_simple_function_all(self, node, pos_args):
"""Transform """Transform
_result = all(x for L in LL for x in L) _result = all(p(x) for L in LL for x in L)
into into
for L in LL: for L in LL:
for x in L: for x in L:
if not x: if not p(x):
_result = False _result = False
break break
else: else:
...@@ -1539,13 +1539,13 @@ class EarlyReplaceBuiltinCalls(Visitor.EnvTransform): ...@@ -1539,13 +1539,13 @@ class EarlyReplaceBuiltinCalls(Visitor.EnvTransform):
def _handle_simple_function_any(self, node, pos_args): def _handle_simple_function_any(self, node, pos_args):
"""Transform """Transform
_result = any(x for L in LL for x in L) _result = any(p(x) for L in LL for x in L)
into into
for L in LL: for L in LL:
for x in L: for x in L:
if x: if p(x):
_result = True _result = True
break break
else: else:
......
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