From 79624ce8490c0a367a57a001f780c62036e93920 Mon Sep 17 00:00:00 2001 From: Florent Kermarrec Date: Tue, 2 Jun 2015 19:26:42 +0200 Subject: [PATCH] migen/genlib/fsm: fix delayed_enter when delay is negative (can happen when delay is generated from others parameters) --- migen/genlib/fsm.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/migen/genlib/fsm.py b/migen/genlib/fsm.py index 6ad3083c..7a2ee619 100644 --- a/migen/genlib/fsm.py +++ b/migen/genlib/fsm.py @@ -74,7 +74,7 @@ class FSM(Module): def delayed_enter(self, name, target, delay): if self.finalized: raise FinalizeError - if delay: + if delay > 0: state = name for i in range(delay): if i == delay - 1: -- 2.30.2