3
0
Fork 0
mirror of https://github.com/YosysHQ/yosys synced 2025-07-30 16:03:17 +00:00

Use selection helpers

Catch more uses of selection constructor without assigning a design.
This commit is contained in:
Krystine Sherwin 2025-03-14 14:08:13 +13:00
parent a67b57bd64
commit dac2bb7d4d
No known key found for this signature in database
23 changed files with 84 additions and 78 deletions

View file

@ -216,8 +216,8 @@ struct DesignPass : public Pass {
RTLIL::Selection sel;
if (argidx != args.size()) {
handle_extra_select_args(this, args, argidx, args.size(), copy_from_design);
sel = copy_from_design->selection_stack.back();
copy_from_design->selection_stack.pop_back();
sel = copy_from_design->selection();
copy_from_design->pop_selection();
argidx = args.size();
}
@ -368,7 +368,7 @@ struct DesignPass : public Pass {
design->selection_vars.clear();
design->selected_active_module.clear();
design->selection_stack.push_back(RTLIL::Selection());
design->push_full_selection();
}
if (reset_mode || reset_vlog_mode || !load_name.empty() || push_mode || pop_mode)