mirror of
https://github.com/YosysHQ/yosys
synced 2025-04-23 17:15:33 +00:00
Remember global declarations and defines accross read_verilog calls
This commit is contained in:
parent
a2206180d6
commit
a926a6afc2
6 changed files with 23 additions and 8 deletions
|
@ -306,6 +306,8 @@ RTLIL::Design::~Design()
|
|||
delete it->second;
|
||||
for (auto n : verilog_packages)
|
||||
delete n;
|
||||
for (auto n : verilog_globals)
|
||||
delete n;
|
||||
}
|
||||
|
||||
RTLIL::ObjRange<RTLIL::Module*> RTLIL::Design::modules()
|
||||
|
|
|
@ -793,7 +793,8 @@ struct RTLIL::Design
|
|||
|
||||
int refcount_modules_;
|
||||
dict<RTLIL::IdString, RTLIL::Module*> modules_;
|
||||
std::vector<AST::AstNode*> verilog_packages;
|
||||
std::vector<AST::AstNode*> verilog_packages, verilog_globals;
|
||||
dict<std::string, std::pair<std::string, bool>> verilog_defines;
|
||||
|
||||
std::vector<RTLIL::Selection> selection_stack;
|
||||
dict<RTLIL::IdString, RTLIL::Selection> selection_vars;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue