Ignore $scopeinfo in write_json

This commit is contained in:
Jannis Harder 2024-01-12 14:14:01 +01:00
parent f31fb95963
commit bbe39762ad
1 changed files with 4 additions and 0 deletions

View File

@ -192,6 +192,10 @@ struct JsonWriter
for (auto c : module->cells()) {
if (use_selection && !module->selected(c))
continue;
// Eventually we will want to emit $scopeinfo, but currently this
// will break JSON netlist consumers like nextpnr
if (c->type == ID($scopeinfo))
continue;
f << stringf("%s\n", first ? "" : ",");
f << stringf(" %s: {\n", get_name(c->name).c_str());
f << stringf(" \"hide_name\": %s,\n", c->name[0] == '$' ? "1" : "0");