diff options
Diffstat (limited to 'frontend/frontend_base.h')
-rw-r--r-- | frontend/frontend_base.h | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/frontend/frontend_base.h b/frontend/frontend_base.h index 4fb71076..bc85fabb 100644 --- a/frontend/frontend_base.h +++ b/frontend/frontend_base.h @@ -134,7 +134,7 @@ template <typename FrontendType> struct GenericFrontend m.path = top; ctx->top_module = top; // Do the actual import, starting from the top level module - import_module(m, top.str(ctx), top.str(ctx), mod_refs.at(top)); + import_module(m, top.str(ctx), top.str(ctx), mod_refs.at(top.str(ctx))); ctx->design_loaded = true; } @@ -149,7 +149,7 @@ template <typename FrontendType> struct GenericFrontend using bitvector_t = typename FrontendType::BitVectorDataType; dict<IdString, ModuleInfo> mods; - std::unordered_map<IdString, const mod_dat_t> mod_refs; + std::unordered_map<std::string, const mod_dat_t> mod_refs; IdString top; // Process the list of modules and determine @@ -159,7 +159,7 @@ template <typename FrontendType> struct GenericFrontend impl.foreach_module([&](const std::string &name, const mod_dat_t &mod) { IdString mod_id = ctx->id(name); auto &mi = mods[mod_id]; - mod_refs.emplace(mod_id, mod); + mod_refs.emplace(name, mod); impl.foreach_attr(mod, [&](const std::string &name, const Property &value) { if (name == "top") mi.is_top = (value.intval != 0); @@ -531,7 +531,7 @@ template <typename FrontendType> struct GenericFrontend ctx->hierarchy[m.path].hier_cells[ctx->id(name)] = submod.path; // Do the submodule import auto type = impl.get_cell_type(cd); - import_module(submod, name, type, mod_refs.at(ctx->id(type))); + import_module(submod, name, type, mod_refs.at(type)); } // Import the cells section of a module |