From 579b98c5963c2b86d191d481a2147a663a8196dd Mon Sep 17 00:00:00 2001 From: gatecat Date: Tue, 1 Jun 2021 16:51:18 +0100 Subject: Use hashlib for core netlist structures Signed-off-by: gatecat --- json/jsonwrite.cc | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'json/jsonwrite.cc') diff --git a/json/jsonwrite.cc b/json/jsonwrite.cc index f92b7038..dbf43351 100644 --- a/json/jsonwrite.cc +++ b/json/jsonwrite.cc @@ -45,7 +45,7 @@ std::string get_string(std::string str) std::string get_name(IdString name, Context *ctx) { return get_string(name.c_str(ctx)); } -void write_parameters(std::ostream &f, Context *ctx, const std::unordered_map ¶meters, +void write_parameters(std::ostream &f, Context *ctx, const dict ¶meters, bool for_module = false) { bool first = true; @@ -64,8 +64,7 @@ struct PortGroup PortType dir; }; -std::vector group_ports(Context *ctx, const std::unordered_map &ports, - bool is_cell = false) +std::vector group_ports(Context *ctx, const dict &ports, bool is_cell = false) { std::vector groups; std::unordered_map base_to_group; -- cgit v1.2.3 From eca1a4cee4f310c7e2c1216bd678143c1967edd4 Mon Sep 17 00:00:00 2001 From: gatecat Date: Wed, 2 Jun 2021 11:36:56 +0100 Subject: Use hashlib in most remaining code Signed-off-by: gatecat --- json/jsonwrite.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'json/jsonwrite.cc') diff --git a/json/jsonwrite.cc b/json/jsonwrite.cc index dbf43351..88d66519 100644 --- a/json/jsonwrite.cc +++ b/json/jsonwrite.cc @@ -67,7 +67,7 @@ struct PortGroup std::vector group_ports(Context *ctx, const dict &ports, bool is_cell = false) { std::vector groups; - std::unordered_map base_to_group; + dict base_to_group; for (auto &pair : ports) { std::string name = pair.second.name.str(ctx); if ((name.back() != ']') || (name.find('[') == std::string::npos)) { -- cgit v1.2.3