Internal cleanup: avoid discarding the result of NodeTransformer visitor, for consistency. This is a no-op, because generic_visit doesn't ever replace the node, so the CL is purely for consistency.
PiperOrigin-RevId: 259380818
This commit is contained in:
parent
5334adcddb
commit
b0cd40d7c7
@ -347,7 +347,7 @@ class ControlFlowTransformer(converter.Base):
|
|||||||
return loop_vars, loop_vars_ast_tuple
|
return loop_vars, loop_vars_ast_tuple
|
||||||
|
|
||||||
def visit_While(self, node):
|
def visit_While(self, node):
|
||||||
self.generic_visit(node)
|
node = self.generic_visit(node)
|
||||||
|
|
||||||
(basic_loop_vars, composite_loop_vars, reserved_symbols,
|
(basic_loop_vars, composite_loop_vars, reserved_symbols,
|
||||||
possibly_undefs) = self._get_loop_vars(
|
possibly_undefs) = self._get_loop_vars(
|
||||||
@ -419,7 +419,7 @@ class ControlFlowTransformer(converter.Base):
|
|||||||
return undefined_assigns + node
|
return undefined_assigns + node
|
||||||
|
|
||||||
def visit_For(self, node):
|
def visit_For(self, node):
|
||||||
self.generic_visit(node)
|
node = self.generic_visit(node)
|
||||||
|
|
||||||
(basic_loop_vars, composite_loop_vars,
|
(basic_loop_vars, composite_loop_vars,
|
||||||
reserved_symbols, possibly_undefs) = self._get_loop_vars(
|
reserved_symbols, possibly_undefs) = self._get_loop_vars(
|
||||||
|
Loading…
Reference in New Issue
Block a user