From fa7f6af01f37c321385cad5f3b4ac866eb5e8834 Mon Sep 17 00:00:00 2001 From: Peter Conrad Date: Wed, 3 Oct 2018 10:31:57 +0200 Subject: [PATCH] Delete broken (wrt fc::current_thread()) move stuff --- include/fc/thread/thread.hpp | 6 +++--- src/thread/thread.cpp | 10 ---------- 2 files changed, 3 insertions(+), 13 deletions(-) diff --git a/include/fc/thread/thread.hpp b/include/fc/thread/thread.hpp index aea55da..933832f 100644 --- a/include/fc/thread/thread.hpp +++ b/include/fc/thread/thread.hpp @@ -22,8 +22,8 @@ namespace fc { class thread { public: thread( const std::string& name = "" ); - thread( thread&& m ); - thread& operator=(thread&& t ); + thread( thread&& m ) = delete; + thread& operator=(thread&& t ) = delete; /** * Returns the current thread. @@ -130,7 +130,7 @@ namespace fc { return wait_any_until(fc::move(proms), fc::time_point::now()+timeout_us ); } private: - thread( class thread_d* ); + thread( class thread_d* ); // parameter is ignored, will create a new thread_d friend class promise_base; friend class task_base; friend class thread_d; diff --git a/src/thread/thread.cpp b/src/thread/thread.cpp index 4da20b3..dd1dbdc 100644 --- a/src/thread/thread.cpp +++ b/src/thread/thread.cpp @@ -98,16 +98,6 @@ namespace fc { my = new thread_d(*this); } - thread::thread( thread&& m ) { - my = m.my; - m.my = 0; - } - - thread& thread::operator=(thread&& t ) { - fc_swap(t.my,my); - return *this; - } - thread::~thread() { //wlog( "my ${n}", ("n",name()) ); if( my )