diff --git a/numba_rvsdg/core/datastructures/ast_transforms.py b/numba_rvsdg/core/datastructures/ast_transforms.py index 86f4628..665577c 100644 --- a/numba_rvsdg/core/datastructures/ast_transforms.py +++ b/numba_rvsdg/core/datastructures/ast_transforms.py @@ -686,8 +686,8 @@ def transform( lineno=0, decorator_list=original.decorator_list, returns=original.returns, - ) - return fdef + ) # type: ignore + return fdef # type: ignore def lookup(self, item: Any) -> Any: subregion_scfg = self.region_stack[-1].subregion @@ -714,7 +714,7 @@ def codegen(self, block: Any) -> list[ast.AST]: test = block.tree[-1].value # type: ignore body = self.codegen(self.lookup(block.jump_targets[0])) orelse = self.codegen(self.lookup(block.jump_targets[1])) - if_node = ast.If(test, body, orelse) + if_node = ast.If(test, body, orelse) # type: ignore return block.tree[:-1] + [if_node] elif block.fallthrough and type(block.tree[-1]) is ast.Return: # The value of the ast.Return could be either None or an @@ -850,8 +850,10 @@ def if_cascade(jump_targets: list[str]) -> list[ast.AST]: # recurse for the rest of the jump_targets. if_node = ast.If( test=if_test, - body=self.codegen(self.lookup(current)), - orelse=if_cascade(jump_targets), + body=self.codegen( + self.lookup(current) + ), # type: ignore + orelse=if_cascade(jump_targets), # type: ignore ) return [if_node]