mirror of
https://github.com/YosysHQ/yosys
synced 2025-11-03 13:07:58 +00:00
Make SigSpec::has_const(State) use chunk iterator
This commit is contained in:
parent
213d665ae1
commit
7bd6b4f287
1 changed files with 2 additions and 3 deletions
|
|
@ -5508,9 +5508,8 @@ bool RTLIL::SigSpec::has_const(State state) const
|
|||
{
|
||||
cover("kernel.rtlil.sigspec.has_const");
|
||||
|
||||
pack();
|
||||
for (auto it = chunks_.begin(); it != chunks_.end(); it++)
|
||||
if (it->width > 0 && it->wire == NULL && std::find(it->data.begin(), it->data.end(), state) != it->data.end())
|
||||
for (auto &chunk : chunks())
|
||||
if (chunk.width > 0 && chunk.wire == NULL && std::find(chunk.data.begin(), chunk.data.end(), state) != chunk.data.end())
|
||||
return true;
|
||||
return false;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue