Skip to content

Commit

Permalink
back.pysim: fix an off-by-1 in add_sync_process().
Browse files Browse the repository at this point in the history
  • Loading branch information
whitequark committed Dec 18, 2018
1 parent 34b81d0 commit 6570271
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions nmigen/back/pysim.py
Original file line number Diff line number Diff line change
Expand Up @@ -342,10 +342,11 @@ def sync_process():
try:
result = None
while True:
self._process_loc[sync_process] = self._name_process(process)
result = process.send(result)
if result is None:
result = Tick(domain)
self._process_loc[sync_process] = self._name_process(process)
result = process.send((yield result))
result = yield result
except StopIteration:
pass
sync_process = sync_process()
Expand Down

0 comments on commit 6570271

Please sign in to comment.