Closed
Description
Repro:
from nmigen.back import rtlil
from nmigen_soc import csr
csr_mux = csr.Multiplexer(addr_width=16, data_width=8, alignment=8)
csr_mux.add(csr.Element(1, "r"))
print(rtlil.convert(csr_mux))
Output:
<snip>
File "/home/jf/src/nmigen/nmigen/hdl/ast.py", line 546, in <lambda>
op_shapes = list(map(lambda x: x.shape(), self.operands))
File "/home/jf/src/nmigen/nmigen/hdl/ast.py", line 546, in shape
op_shapes = list(map(lambda x: x.shape(), self.operands))
File "/home/jf/src/nmigen/nmigen/hdl/ast.py", line 546, in <lambda>
op_shapes = list(map(lambda x: x.shape(), self.operands))
File "/home/jf/src/nmigen/nmigen/hdl/ast.py", line 546, in shape
op_shapes = list(map(lambda x: x.shape(), self.operands))
File "/home/jf/src/nmigen/nmigen/hdl/ast.py", line 546, in <lambda>
op_shapes = list(map(lambda x: x.shape(), self.operands))
File "/home/jf/src/nmigen/nmigen/hdl/ast.py", line 546, in shape
op_shapes = list(map(lambda x: x.shape(), self.operands))
File "/home/jf/src/nmigen/nmigen/hdl/ast.py", line 546, in <lambda>
op_shapes = list(map(lambda x: x.shape(), self.operands))
File "/home/jf/src/nmigen/nmigen/hdl/ast.py", line 546, in shape
op_shapes = list(map(lambda x: x.shape(), self.operands))
File "/home/jf/src/nmigen/nmigen/hdl/ast.py", line 546, in <lambda>
op_shapes = list(map(lambda x: x.shape(), self.operands))
File "/home/jf/src/nmigen/nmigen/hdl/ast.py", line 643, in shape
return Shape(self.stop - self.start)
File "<string>", line 1, in __new__
RecursionError: maximum recursion depth exceeded while calling a Python object