diff --git a/src/corelib/tools/qhash.h b/src/corelib/tools/qhash.h index f9bb02017fd..faf3e9f9535 100644 --- a/src/corelib/tools/qhash.h +++ b/src/corelib/tools/qhash.h @@ -1387,11 +1387,11 @@ public: { return takeImpl(key); } - bool contains(const QHashPrivate::HeterogeneouslySearchableWith auto &key) + bool contains(const QHashPrivate::HeterogeneouslySearchableWith auto &key) const { return d ? d->findNode(key) != nullptr : false; } - qsizetype count(const QHashPrivate::HeterogeneouslySearchableWith auto &key) + qsizetype count(const QHashPrivate::HeterogeneouslySearchableWith auto &key) const { return contains(key) ? 1 : 0; }