mirror of https://github.com/YosysHQ/yosys.git
Recognise default entry in case even if all cases covered (#931)
This commit is contained in:
parent
0deaccbaae
commit
adc6efb584
|
@ -34,7 +34,7 @@ void proc_rmdead(RTLIL::SwitchRule *sw, int &counter)
|
|||
|
||||
for (size_t i = 0; i < sw->cases.size(); i++)
|
||||
{
|
||||
bool is_default = GetSize(sw->cases[i]->compare) == 0 && (!pool.empty() || GetSize(sw->signal) == 0);
|
||||
bool is_default = GetSize(sw->cases[i]->compare) == 0 || GetSize(sw->signal) == 0;
|
||||
|
||||
for (size_t j = 0; j < sw->cases[i]->compare.size(); j++) {
|
||||
RTLIL::SigSpec sig = sw->cases[i]->compare[j];
|
||||
|
|
Loading…
Reference in New Issue