Skip to content

Commit

Permalink
fix variable
Browse files Browse the repository at this point in the history
  • Loading branch information
charles-cooper committed Oct 1, 2024
1 parent 04c7124 commit 1e64727
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion vyper/codegen/stmt.py
Original file line number Diff line number Diff line change
Expand Up @@ -214,9 +214,10 @@ def _parse_For_range(self):
raise TypeCheckFailure("unreachable: unchecked 0 bound")

varname = self.stmt.target.target.id
assert varname not in forvars

i = IRnode.from_list(self.context.fresh_varname("range_ix"), typ=target_type)

assert varname not in self.context.forvars
self.context.forvars[varname] = i

loop_body = ["seq"]
Expand Down

0 comments on commit 1e64727

Please sign in to comment.