Skip to content

Commit 2ea2c7b

Browse files
[pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
1 parent cac0740 commit 2ea2c7b

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

mypyc/irbuild/constant_fold.py

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,9 @@ def constant_fold_expr(builder: IRBuilder, expr: Expression) -> ConstantValue |
8989
and isinstance(arg := args[0], (ListExpr, TupleExpr))
9090
):
9191
folded_items = constant_fold_container_expr(builder, arg)
92-
if folded_items is not None and all(isinstance(item, str) for item in folded_items):
92+
if folded_items is not None and all(
93+
isinstance(item, str) for item in folded_items
94+
):
9395
return folded_callee.join(folded_items)
9496

9597
# builtins.bytes methods
@@ -102,7 +104,9 @@ def constant_fold_expr(builder: IRBuilder, expr: Expression) -> ConstantValue |
102104
and isinstance(arg := args[0], (ListExpr, TupleExpr))
103105
):
104106
folded_items = constant_fold_container_expr(builder, arg)
105-
if folded_items is not None and all(isinstance(item, bytes) for item in folded_items):
107+
if folded_items is not None and all(
108+
isinstance(item, bytes) for item in folded_items
109+
):
106110
return folded_callee.join(folded_items)
107111
return None
108112

0 commit comments

Comments
 (0)