3
0
Fork 0
mirror of https://github.com/YosysHQ/yosys synced 2025-04-24 01:25:33 +00:00

select.cc: Fix %i when rhs is empty

This commit is contained in:
Krystine Sherwin 2025-03-14 14:08:16 +13:00
parent 2dec493054
commit 38293d3bdf
No known key found for this signature in database

View file

@ -431,9 +431,17 @@ static void select_op_intersect(RTLIL::Design *design, RTLIL::Selection &lhs, co
if (rhs.full_selection && !lhs.selects_boxes)
return;
if (lhs.empty() || rhs.empty())
if (lhs.empty())
return;
if (rhs.empty()) {
lhs.full_selection = false;
lhs.complete_selection = false;
lhs.selected_modules.clear();
lhs.selected_members.clear();
return;
}
select_all(design, lhs);
std::vector<RTLIL::IdString> del_list;