mirror of
https://github.com/YosysHQ/yosys
synced 2025-11-05 13:56:04 +00:00
Simplify SigSpec::as_bit()
This commit is contained in:
parent
be530bef73
commit
d314c47a55
1 changed files with 1 additions and 6 deletions
|
|
@ -5623,12 +5623,7 @@ RTLIL::SigChunk RTLIL::SigSpec::as_chunk() const
|
||||||
RTLIL::SigBit RTLIL::SigSpec::as_bit() const
|
RTLIL::SigBit RTLIL::SigSpec::as_bit() const
|
||||||
{
|
{
|
||||||
cover("kernel.rtlil.sigspec.as_bit");
|
cover("kernel.rtlil.sigspec.as_bit");
|
||||||
|
return RTLIL::SigBit(*this);
|
||||||
log_assert(width_ == 1);
|
|
||||||
if (packed())
|
|
||||||
return RTLIL::SigBit(*chunks_.begin());
|
|
||||||
else
|
|
||||||
return bits_[0];
|
|
||||||
}
|
}
|
||||||
|
|
||||||
bool RTLIL::SigSpec::match(const char* pattern) const
|
bool RTLIL::SigSpec::match(const char* pattern) const
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue