Skip to content

Commit

Permalink
ignore existing mypy errors
Browse files Browse the repository at this point in the history
As title
  • Loading branch information
esc committed Jul 22, 2024
1 parent a62d428 commit ee85c65
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions numba_rvsdg/core/datastructures/ast_transforms.py
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand All @@ -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
Expand Down Expand Up @@ -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]

Expand Down

0 comments on commit ee85c65

Please sign in to comment.