mirror of
https://github.com/YosysHQ/yosys
synced 2025-06-06 06:03:23 +00:00
Added design->rename(module, new_name)
This commit is contained in:
parent
df0163cd2b
commit
caa274ada6
3 changed files with 9 additions and 3 deletions
|
@ -444,6 +444,13 @@ void RTLIL::Design::remove(RTLIL::Module *module)
|
|||
delete module;
|
||||
}
|
||||
|
||||
void RTLIL::Design::rename(RTLIL::Module *module, RTLIL::IdString new_name)
|
||||
{
|
||||
modules_.erase(module->name);
|
||||
module->name = new_name;
|
||||
add(module);
|
||||
}
|
||||
|
||||
void RTLIL::Design::sort()
|
||||
{
|
||||
scratchpad.sort();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue