summaryrefslogtreecommitdiffstats
path: root/src/corelib/thread/qpromise.qdoc
diff options
context:
space:
mode:
authorAndrei Golubev <andrei.golubev@qt.io>2020-07-24 12:30:00 +0200
committerAndrei Golubev <andrei.golubev@qt.io>2020-08-03 16:47:31 +0200
commitb3c1093751072110d34b9746d419e8070c80fc3f (patch)
tree6efa2be54684b03d57f3f299247f0a14f144d82e /src/corelib/thread/qpromise.qdoc
parentfddb0c895f9a12d61bbc4cf33149a8d1a93eaf19 (diff)
Introduce swap functions for QPromise/QFutureInterface
Made QPromise::swap public, added free standing swap() for QFutureInterface and QPromise. Updated QPromise special member functions. Extended tests Task-number: QTBUG-84977 Change-Id: I5daf6876df306d082441dbcdf5ae4dee3bfc0ead Reviewed-by: Sona Kurazyan <sona.kurazyan@qt.io>
Diffstat (limited to 'src/corelib/thread/qpromise.qdoc')
-rw-r--r--src/corelib/thread/qpromise.qdoc5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/corelib/thread/qpromise.qdoc b/src/corelib/thread/qpromise.qdoc
index e78e16bdd6..b404732a9e 100644
--- a/src/corelib/thread/qpromise.qdoc
+++ b/src/corelib/thread/qpromise.qdoc
@@ -229,3 +229,8 @@
\sa QFuture::progressValue(), QFuture::progressText(), QFuture::cancel(),
reportFinished()
*/
+
+/*! \fn template<typename T> void QPromise<T>::swap(QPromise<T> &other) noexcept
+
+ Swaps promise \a other with this promise. This operation is very fast and never fails.
+*/