diff --git a/src/corelib/compat/removed_api.cpp b/src/corelib/compat/removed_api.cpp index 316c3518501..8260d50fd3a 100644 --- a/src/corelib/compat/removed_api.cpp +++ b/src/corelib/compat/removed_api.cpp @@ -1461,6 +1461,8 @@ QNoDebug QMessageLogger::noDebug() const noexcept return QNoDebug(); } +#include "qmutex.h" // removed, previously-inline API + #include "qstring.h" // inlined API // #include "qotherheader.h" diff --git a/src/corelib/thread/qmutex.h b/src/corelib/thread/qmutex.h index 68377f3d699..a45dcee2756 100644 --- a/src/corelib/thread/qmutex.h +++ b/src/corelib/thread/qmutex.h @@ -88,6 +88,11 @@ private: return false; return d_ptr.testAndSetAcquire(nullptr, dummyLocked()); } +#if QT_CORE_REMOVED_SINCE(6, 10) + inline bool fastTryUnlock() noexcept { + return d_ptr.testAndSetRelease(dummyLocked(), nullptr); + } +#endif void lockInternal() noexcept(FutexAlwaysAvailable); bool lockInternal(QDeadlineTimer timeout) noexcept(FutexAlwaysAvailable);