Skip to content

Commit 2408fb0

Browse files
fix mypy
1 parent f2fc3fc commit 2408fb0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Tools/cases_generator/optimizer_generator.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -165,6 +165,7 @@ def replace_opcode_if_evaluates_pure(
165165
storage: Storage,
166166
inst: Instruction | None,
167167
) -> bool:
168+
assert isinstance(uop, Uop)
168169
input_identifiers = []
169170
for token in tkn_iter:
170171
if token.kind == "IDENTIFIER":
@@ -191,7 +192,6 @@ def replace_opcode_if_evaluates_pure(
191192
assert len(used_stack_inputs) > 0
192193
emitter = OptimizerConstantEmitter(self.out, {}, self.original_uop, self.stack.copy())
193194
emitter.emit("if (\n")
194-
assert isinstance(uop, Uop)
195195
for inp in used_stack_inputs[:-1]:
196196
emitter.emit(f"sym_is_safe_const(ctx, {inp.name}) &&\n")
197197
emitter.emit(f"sym_is_safe_const(ctx, {used_stack_inputs[-1].name})\n")

0 commit comments

Comments
 (0)