From: Arnaud Giersch Date: Thu, 14 Mar 2019 12:54:27 +0000 (+0100) Subject: Define move-assignment and delete copy-assignment operators for xbt::Task. X-Git-Tag: v3_22~96^2~3 X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/commitdiff_plain/74c5de07784abf609331bcf7242145cc4affdaab Define move-assignment and delete copy-assignment operators for xbt::Task. --- diff --git a/include/xbt/functional.hpp b/include/xbt/functional.hpp index 608d372891..9ca66f816e 100644 --- a/include/xbt/functional.hpp +++ b/include/xbt/functional.hpp @@ -175,7 +175,8 @@ public: vtable_ = that.vtable_; that.vtable_ = nullptr; } - Task& operator=(Task that) + Task& operator=(Task const& that) = delete; + Task& operator=(Task&& that) { this->clear(); if (that.vtable_ && that.vtable_->move)