mirror of
https://github.com/YosysHQ/yosys
synced 2025-06-07 06:33:24 +00:00
Using std::move() in SigSpec move constructor
This commit is contained in:
parent
7f3dc86ecd
commit
ddc5b41848
1 changed files with 4 additions and 4 deletions
|
@ -628,15 +628,15 @@ public:
|
||||||
SigSpec(RTLIL::SigSpec &&other) {
|
SigSpec(RTLIL::SigSpec &&other) {
|
||||||
width_ = other.width_;
|
width_ = other.width_;
|
||||||
hash_ = other.hash_;
|
hash_ = other.hash_;
|
||||||
chunks_.swap(other.chunks_);
|
chunks_ = std::move(other.chunks_);
|
||||||
bits_.swap(other.bits_);
|
bits_ = std::move(other.bits_);
|
||||||
}
|
}
|
||||||
|
|
||||||
const RTLIL::SigSpec &operator=(RTLIL::SigSpec &&other) {
|
const RTLIL::SigSpec &operator=(RTLIL::SigSpec &&other) {
|
||||||
width_ = other.width_;
|
width_ = other.width_;
|
||||||
hash_ = other.hash_;
|
hash_ = other.hash_;
|
||||||
chunks_.swap(other.chunks_);
|
chunks_ = std::move(other.chunks_);
|
||||||
bits_.swap(other.bits_);
|
bits_ = std::move(other.bits_);
|
||||||
return *this;
|
return *this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue