Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Rename variable to avoid confusing mypy
  • Loading branch information
markshannon committed Aug 8, 2024
commit a392c536bdd0218d4ccbd7277a9d5155ca7c7d6a
12 changes: 6 additions & 6 deletions Tools/cases_generator/stack.py
Original file line number Diff line number Diff line change
Expand Up @@ -325,15 +325,15 @@ def flush_single_var(
top_offset = self.top_offset.copy()
for var in self.variables:
base_offset.push(var.item)
for var in outputs:
if any(var == v.item for v in self.variables):
for output in outputs:
if any(output == v.item for v in self.variables):
# The variable is already on the stack, such as a peeked value
# in the tier1 generator
continue
if var.name == var_name:
Stack._do_emit(out, var, base_offset, cast_type, extract_bits)
base_offset.push(var)
top_offset.push(var)
if output.name == var_name:
Stack._do_emit(out, output, base_offset, cast_type, extract_bits)
base_offset.push(output)
top_offset.push(output)
if base_offset.to_c() != top_offset.to_c():
print("base", base_offset, "top", top_offset)
assert False
Expand Down