3
0
Fork 0
mirror of https://github.com/YosysHQ/yosys synced 2025-07-24 05:08:56 +00:00

Add Selection::clear() method

Use method in `select.cc` to reduce code duplication.
This commit is contained in:
Krystine Sherwin 2025-04-05 10:56:01 +13:00
parent dab67f84da
commit d8a9ad6860
No known key found for this signature in database
3 changed files with 17 additions and 20 deletions

View file

@ -1241,6 +1241,9 @@ struct RTLIL::Selection
return !selects_all() && selected_modules.empty() && selected_members.empty();
}
// clear this selection, leaving it empty
void clear();
// create a new selection which is empty
static Selection EmptySelection(RTLIL::Design *design = nullptr) { return Selection(false, false, design); };