ThreadPoolThreadReleaser: add Q_NODISCARD_CTOR

QUIP: 19
Pick-to: 6.6
Change-Id: I465a2ef8edc103f0655a7732f3aaaf18748854c4
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
This commit is contained in:
Marc Mutz 2023-07-12 17:45:57 +02:00
parent f1ffc11e61
commit df96d39c04

View File

@ -30,6 +30,7 @@ namespace {
class ThreadPoolThreadReleaser {
QThreadPool *m_pool;
public:
Q_NODISCARD_CTOR
explicit ThreadPoolThreadReleaser(QThreadPool *pool)
: m_pool(pool)
{ if (pool) pool->releaseThread(); }