added a move contructor to ThreadC
This commit is contained in:
parent
c274cc0fb4
commit
57201a2af3
@ -34,7 +34,7 @@
|
|||||||
#include <qse/types.h>
|
#include <qse/types.h>
|
||||||
#include <qse/macros.h>
|
#include <qse/macros.h>
|
||||||
|
|
||||||
#if (__cplusplus >= 201103L) // C++11
|
#if (__cplusplus >= 201103L) || (defined(_MSC_VER) && _MSC_VER >= 1900) // C++11 or later
|
||||||
|
|
||||||
#define QSE_CPP_NOEXCEPT noexcept(true)
|
#define QSE_CPP_NOEXCEPT noexcept(true)
|
||||||
#define QSE_CPP_EXPLICIT explicit
|
#define QSE_CPP_EXPLICIT explicit
|
||||||
|
@ -118,8 +118,10 @@ class ThreadC: public Thread
|
|||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
ThreadC () {}
|
ThreadC () {}
|
||||||
ThreadC (F& f): __lfunc(f) { }
|
ThreadC (const F& f): __lfunc(f) {}
|
||||||
//ThreadC (F&& f): __lfunc(QSE_CPP_RVREF(f)) { }
|
#if defined(QSE_CPP_ENABLE_CPP11_MOVE)
|
||||||
|
ThreadC (F&& f): __lfunc(QSE_CPP_RVREF(f)) {}
|
||||||
|
#endif
|
||||||
|
|
||||||
static int call_func (qse_thr_t* thr, void* ctx)
|
static int call_func (qse_thr_t* thr, void* ctx)
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user