Skip to content

Commit

Permalink
Add move-assignment to Mtbdd class
Browse files Browse the repository at this point in the history
Again, nothing is really gained from doing so except more code.
  • Loading branch information
SSoelvsten committed Apr 12, 2024
1 parent 0355ba8 commit 0c6fd08
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/sylvan_obj.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -754,6 +754,13 @@ Mtbdd::operator=(const Mtbdd& right)
return *this;
}

Mtbdd&
Mtbdd::operator=(Mtbdd&& right)
{
mtbdd = right.mtbdd;
return *this;
}

Mtbdd
Mtbdd::operator!() const
{
Expand Down
1 change: 1 addition & 0 deletions src/sylvan_obj.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -717,6 +717,7 @@ class Mtbdd {
bool operator==(const Mtbdd& other) const;
bool operator!=(const Mtbdd& other) const;
Mtbdd& operator=(const Mtbdd& right);
Mtbdd& operator=(Mtbdd&& right);
Mtbdd operator!() const;
Mtbdd operator~() const;
Mtbdd operator*(const Mtbdd& other) const;
Expand Down

0 comments on commit 0c6fd08

Please sign in to comment.