mirror of
https://github.com/Silicon1602/srdl2sv.git
synced 2024-12-22 15:08:39 +00:00
Package with enums shall not be dumped if no enums are present
This commit is contained in:
parent
6e355c62af
commit
b23ddded74
@ -371,10 +371,14 @@ class AddrMap(Component):
|
|||||||
|
|
||||||
# Create RTL to return
|
# Create RTL to return
|
||||||
for key, value in enum_rtl.items():
|
for key, value in enum_rtl.items():
|
||||||
|
if not value:
|
||||||
|
# Skip if package wouldn't contain any enums
|
||||||
|
continue
|
||||||
|
|
||||||
package_rtl =\
|
package_rtl =\
|
||||||
AddrMap.templ_dict['package_declaration']['rtl'].format(
|
AddrMap.templ_dict['package_declaration']['rtl'].format(
|
||||||
name = key,
|
name = key,
|
||||||
pkg_content = '\n\n'.join(enum_rtl[key]))
|
pkg_content = '\n\n'.join(value))
|
||||||
|
|
||||||
|
|
||||||
rtl_return[key] = AddrMap.add_tabs(
|
rtl_return[key] = AddrMap.add_tabs(
|
||||||
|
Loading…
Reference in New Issue
Block a user