aboutsummaryrefslogtreecommitdiffstats
path: root/json/jsonwrite.cc
diff options
context:
space:
mode:
authorgatecat <gatecat@ds0.me>2021-06-03 09:04:34 +0100
committerGitHub <noreply@github.com>2021-06-03 09:04:34 +0100
commita3d8b4f9d198226ec0903e34a8d290b376b45c0b (patch)
treeada2c6a5d48e766fa523e633aaa28179baea3273 /json/jsonwrite.cc
parent589ca8ded5da2012e4388a3ec4c8fae74dff75e4 (diff)
parentdcbb322447a7fb59cabe197ec1dd2307acfa3681 (diff)
downloadnextpnr-a3d8b4f9d198226ec0903e34a8d290b376b45c0b.tar.gz
nextpnr-a3d8b4f9d198226ec0903e34a8d290b376b45c0b.tar.bz2
nextpnr-a3d8b4f9d198226ec0903e34a8d290b376b45c0b.zip
Merge pull request #718 from YosysHQ/gatecat/hashlib
Moving from unordered_{map, set} to hashlib
Diffstat (limited to 'json/jsonwrite.cc')
-rw-r--r--json/jsonwrite.cc7
1 files changed, 3 insertions, 4 deletions
diff --git a/json/jsonwrite.cc b/json/jsonwrite.cc
index f92b7038..88d66519 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<IdString, Property> &parameters,
+void write_parameters(std::ostream &f, Context *ctx, const dict<IdString, Property> &parameters,
bool for_module = false)
{
bool first = true;
@@ -64,11 +64,10 @@ struct PortGroup
PortType dir;
};
-std::vector<PortGroup> group_ports(Context *ctx, const std::unordered_map<IdString, PortInfo> &ports,
- bool is_cell = false)
+std::vector<PortGroup> group_ports(Context *ctx, const dict<IdString, PortInfo> &ports, bool is_cell = false)
{
std::vector<PortGroup> groups;
- std::unordered_map<std::string, size_t> base_to_group;
+ dict<std::string, size_t> base_to_group;
for (auto &pair : ports) {
std::string name = pair.second.name.str(ctx);
if ((name.back() != ']') || (name.find('[') == std::string::npos)) {