back.rtlil: fix handling of certain nested arrays.
This triggers on code like: c1 = Signal() c2 = Signal() c3 = Signal() v1 = Array([Const(1, 8), Const(2, 8)])[c1] v2 = Array([Const(3, 8), Const(4, 8)])[c2] v3 = Array([v1, v2])[c3] Fixes #226.
This commit is contained in:
parent
53bb4300a3
commit
e3a1d05f23
|
@ -718,7 +718,7 @@ class _StatementCompiler(xfrm.StatementVisitor):
|
||||||
self._wrap_assign = False
|
self._wrap_assign = False
|
||||||
branch_value = ast.Const(branch, (width, signed))
|
branch_value = ast.Const(branch, (width, signed))
|
||||||
with self.state.expand_to(legalize.value, branch_value):
|
with self.state.expand_to(legalize.value, branch_value):
|
||||||
super().on_statement(stmt)
|
self.on_statement(stmt)
|
||||||
self._wrap_assign = True
|
self._wrap_assign = True
|
||||||
|
|
||||||
def on_statements(self, stmts):
|
def on_statements(self, stmts):
|
||||||
|
|
Loading…
Reference in a new issue