netlist: Fix namespaces for multi-source subsheets
commit9f35462965b26b5082cc32c212187f23dcb158ba
authorRoland Lutz <rlutz@hedmen.org>
Sun, 6 Dec 2020 19:21:42 +0000 (6 20:21 +0100)
committerRoland Lutz <rlutz@hedmen.org>
Sun, 6 Dec 2020 20:34:51 +0000 (6 21:34 +0100)
tree4e660b225b532079b155a25358810ddf47441b05
parent320ceecc3c0aa3e09d43ac9de75aab7d4fee04be
netlist: Fix namespaces for multi-source subsheets

Components can have multiple source= attributes and thus multiple
subsheets.  However, since the namespace for package and net names
used to be the sheet instance, splitting packages across and
connecting nets between the individual subsheets didn't work.

In order to fix this, use the *instantiating component* instance as
the namespace for package and net names instead.

Reported-by: Klaus Rudolph <lts-rudolph@gmx.de>
14 files changed:
src/backend/util_repackage.py
src/command/netlist.py
src/gaf/netlist/net.py
src/gaf/netlist/netlist.py
src/gaf/netlist/package.py
tests/netlist/Makefile.am
tests/netlist/regression/gschemrc
tests/netlist/regression/multiple_sources-geda.out [new file with mode: 0644]
tests/netlist/regression/multiple_sources-sources/sub-0.sch [new file with mode: 0644]
tests/netlist/regression/multiple_sources-sources/sub-1.sch [new file with mode: 0644]
tests/netlist/regression/multiple_sources-symbols/io.sym [new file with mode: 0644]
tests/netlist/regression/multiple_sources-symbols/sub.sym [new file with mode: 0644]
tests/netlist/regression/multiple_sources-symbols/sym.sym [new file with mode: 0644]
tests/netlist/regression/multiple_sources.sch [new file with mode: 0644]