diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/corelib/thread/qthread.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/corelib/thread/qthread.h b/src/corelib/thread/qthread.h index 7d268cffc9..ab32891a59 100644 --- a/src/corelib/thread/qthread.h +++ b/src/corelib/thread/qthread.h @@ -105,7 +105,7 @@ public: #if QT_CONFIG(cxx11_future) || defined(Q_CLANG_QDOC) template <typename Function, typename... Args> - static QThread *create(Function &&f, Args &&... args); + [[nodiscard]] static QThread *create(Function &&f, Args &&... args); #endif public Q_SLOTS: @@ -143,7 +143,7 @@ private: Q_DECLARE_PRIVATE(QThread) #if QT_CONFIG(cxx11_future) - static QThread *createThreadImpl(std::future<void> &&future); + [[nodiscard]] static QThread *createThreadImpl(std::future<void> &&future); #endif static Qt::HANDLE currentThreadIdImpl() noexcept Q_DECL_PURE_FUNCTION; |