Skip to content

Commit 48ebc0d

Browse files
fix mypy errs
1 parent 6319617 commit 48ebc0d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

mypyc/irbuild/for_helpers.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1210,9 +1210,9 @@ def get_expr_length(expr: Expression) -> int | None:
12101210
elif fullname == "builtins.zip" and expr.args:
12111211
arg_lengths = [get_expr_length(arg) for arg in expr.args]
12121212
if all(arg is not None for arg in arg_lengths):
1213-
return min(arg_lengths)
1213+
return min(arg_lengths) # type: ignore [type-var]
12141214
elif fullname == "builtins.range" and all(isinstance(arg, IntExpr) for arg in expr.args):
1215-
return len(range(*(arg.value for arg in expr.args)))
1215+
return len(range(*(arg.value for arg in expr.args))) # type: ignore [attr-defined]
12161216

12171217
# TODO: extend this, passing length of listcomp and genexp should have worthwhile
12181218
# performance boost and can be (sometimes) figured out pretty easily. set and dict

0 commit comments

Comments
 (0)