diff options
author | Claire Xenia Wolf <claire@clairexen.net> | 2021-04-26 16:31:44 +0200 |
---|---|---|
committer | Claire Xenia Wolf <claire@clairexen.net> | 2021-04-26 16:32:12 +0200 |
commit | 58290c0c77e09aa40a098065ea999c85aaba398c (patch) | |
tree | f28093dbea5299075b3d17cdb1906e3dbebf9370 | |
parent | a5adb007742f0339b0a9663871fd86620d8f6a78 (diff) | |
download | yosys-58290c0c77e09aa40a098065ea999c85aaba398c.tar.gz yosys-58290c0c77e09aa40a098065ea999c85aaba398c.tar.bz2 yosys-58290c0c77e09aa40a098065ea999c85aaba398c.zip |
Remove duplicates from conns array in JSON front-end, fixes #2736
-rw-r--r-- | frontends/json/jsonparse.cc | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/frontends/json/jsonparse.cc b/frontends/json/jsonparse.cc index d897ac20b..cbfa038a1 100644 --- a/frontends/json/jsonparse.cc +++ b/frontends/json/jsonparse.cc @@ -585,6 +585,10 @@ void json_import(Design *design, string &modname, JsonNode *node) module->memories[mem->name] = mem; } } + + // remove duplicates from connections array + pool<RTLIL::SigSig> unique_connections(module->connections_.begin(), module->connections_.end()); + module->connections_ = std::vector<RTLIL::SigSig>(unique_connections.begin(), unique_connections.end()); } struct JsonFrontend : public Frontend { |