3
0
Fork 0
mirror of https://github.com/YosysHQ/yosys synced 2025-06-06 14:13:23 +00:00

added option '-Dname[=definition]' to command 'read_verilog'

This commit is contained in:
Johann Glaser 2013-05-19 17:07:52 +02:00
parent fbadb54b9b
commit 10a195c0a1
3 changed files with 19 additions and 4 deletions

View file

@ -206,9 +206,9 @@ static std::string define_to_feature(std::string defname)
return std::string();
}
std::string frontend_verilog_preproc(FILE *f, std::string filename)
std::string frontend_verilog_preproc(FILE *f, std::string filename, const std::map<std::string, std::string> pre_defines_map)
{
std::map<std::string, std::string> defines_map;
std::map<std::string, std::string> defines_map(pre_defines_map);
int ifdef_fail_level = 0;
output_code.clear();