+ Task() { /* Nothing to do */}
+ explicit Task(std::nullptr_t) { /* Nothing to do */}
+ ~Task()
+ {
+ this->clear();
+ }
+
+ Task(Task const&) = delete;
+
+ Task(Task&& that)
+ {
+ if (that.vtable_ && that.vtable_->move)
+ that.vtable_->move(buffer_, that.buffer_);
+ else
+ std::memcpy(static_cast<void*>(&buffer_), static_cast<void*>(&that.buffer_), sizeof(buffer_));
+
+ vtable_ = that.vtable_;
+ that.vtable_ = nullptr;
+ }
+ Task& operator=(Task that)
+ {
+ this->clear();
+ if (that.vtable_ && that.vtable_->move)
+ that.vtable_->move(buffer_, that.buffer_);
+ else
+ std::memcpy(static_cast<void*>(&buffer_), static_cast<void*>(&that.buffer_), sizeof(buffer_));
+ vtable_ = that.vtable_;
+ that.vtable_ = nullptr;
+ return *this;
+ }
+
+private: