From 1f89900b160f9ec35f975a502abd592e6c57043d Mon Sep 17 00:00:00 2001 From: Sebastien Bourdeauducq Date: Mon, 19 Oct 2015 19:21:20 +0800 Subject: [PATCH] sim: generators are also iterables... --- migen/sim/core.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/migen/sim/core.py b/migen/sim/core.py index b036dbe2c..8ad699136 100644 --- a/migen/sim/core.py +++ b/migen/sim/core.py @@ -211,7 +211,8 @@ class Simulator: generators = {"sys": generators} self.generators = dict() for k, v in generators.items(): - if isinstance(v, collections.Iterable): + if (isinstance(v, collections.Iterable) + and not isinstance(v, collections.Generator)): self.generators[k] = list(v) else: self.generators[k] = [v]