Skip to content

Commit

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

varname = self.stmt.target.target.id
i = IRnode.from_list(self.context.fresh_varname("range_ix"), typ=target_type)

assert varname not in forvars

i = IRnode.from_list(self.context.fresh_varname("range_ix"), typ=target_type)
self.context.forvars[varname] = i

loop_body = ["seq"]
Expand Down

0 comments on commit 04c7124

Please sign in to comment.