diff --git a/src/Tag.cc b/src/Tag.cc index 8f896096f9..6233799585 100644 --- a/src/Tag.cc +++ b/src/Tag.cc @@ -37,6 +37,13 @@ Tag::Tag(const Tag& other) { etype = other.etype; } +Tag::Tag(Tag&& other) noexcept { + type = other.type; + subtype = other.subtype; + val = std::move(other.val); + etype = std::move(other.etype); +} + Tag::Tag() { val = nullptr; etype = nullptr; diff --git a/src/Tag.h b/src/Tag.h index b7239a791e..2d730ba87b 100644 --- a/src/Tag.h +++ b/src/Tag.h @@ -100,6 +100,11 @@ public: */ Tag(const Tag& other); + /** + * Move constructor. + */ + Tag(Tag&& other) noexcept; + /** * Destructor. */