From 6ce856290a8d285a1baf7d5cf02732e425b6e220 Mon Sep 17 00:00:00 2001 From: Sebastien Bourdeauducq Date: Wed, 10 Apr 2013 21:33:56 +0200 Subject: [PATCH] flow: match record fields by position --- migen/flow/actor.py | 8 ++++---- migen/flow/network.py | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/migen/flow/actor.py b/migen/flow/actor.py index 2d7e134c..6d05917f 100644 --- a/migen/flow/actor.py +++ b/migen/flow/actor.py @@ -22,12 +22,12 @@ class _Endpoint(Record): Record.__init__(self, full_layout) class Source(_Endpoint): - def connect(self, sink): - return Record.connect(self, sink) + def connect(self, sink, **kwargs): + return Record.connect(self, sink, **kwargs) class Sink(_Endpoint): - def connect(self, source): - return source.connect(self) + def connect(self, source, **kwargs): + return source.connect(self, **kwargs) def get_endpoints(obj, filt=_Endpoint): if hasattr(obj, "get_endpoints") and callable(obj.get_endpoints): diff --git a/migen/flow/network.py b/migen/flow/network.py index a9970a74..4082720a 100644 --- a/migen/flow/network.py +++ b/migen/flow/network.py @@ -210,4 +210,4 @@ class CompositeActor(Module): for u, v, d in dfg.edges_iter(data=True): ep_src = getattr(u, d["source"]) ep_dst = getattr(v, d["sink"]) - self.comb += ep_src.connect(ep_dst) + self.comb += ep_src.connect(ep_dst, match_by_position=True) -- 2.30.2