summaryrefslogtreecommitdiffstats
path: root/async/src/async.h
diff options
context:
space:
mode:
Diffstat (limited to 'async/src/async.h')
-rw-r--r--async/src/async.h5
1 files changed, 2 insertions, 3 deletions
diff --git a/async/src/async.h b/async/src/async.h
index 171a245..8fee0bc 100644
--- a/async/src/async.h
+++ b/async/src/async.h
@@ -300,8 +300,7 @@ void Executor<PrevOut, Out, In ...>::exec()
300 auto futureWatcher = new Async::FutureWatcher<PrevOut>(); 300 auto futureWatcher = new Async::FutureWatcher<PrevOut>();
301 QObject::connect(futureWatcher, &Async::FutureWatcher<PrevOut>::futureReady, 301 QObject::connect(futureWatcher, &Async::FutureWatcher<PrevOut>::futureReady,
302 [futureWatcher, this]() { 302 [futureWatcher, this]() {
303 //FIXME mFinished is not part of the d-pointer but we copy the future below 303 assert(futureWatcher->future().isFinished());
304 // assert(futureWatcher->future().isFinished());
305 futureWatcher->deleteLater(); 304 futureWatcher->deleteLater();
306 previousFutureReady(); 305 previousFutureReady();
307 }); 306 });
@@ -320,7 +319,7 @@ template<typename Out, typename ... In>
320void ThenExecutor<Out, In ...>::previousFutureReady() 319void ThenExecutor<Out, In ...>::previousFutureReady()
321{ 320{
322 if (this->mPrevFuture) { 321 if (this->mPrevFuture) {
323 assert(this->mPrevFuture->isFinished()); 322 assert(this->mPrevFuture->isFinished());
324 } 323 }
325 this->mFunc(this->mPrevFuture ? this->mPrevFuture->value() : In() ..., 324 this->mFunc(this->mPrevFuture ? this->mPrevFuture->value() : In() ...,
326 *static_cast<Async::Future<Out>*>(this->mResult)); 325 *static_cast<Async::Future<Out>*>(this->mResult));