summaryrefslogtreecommitdiffstats
path: root/src/corelib/tools/qsharedpointer.h
diff options
context:
space:
mode:
authorTarja Sundqvist <tarja.sundqvist@qt.io>2024-01-04 21:21:43 +0200
committerTarja Sundqvist <tarja.sundqvist@qt.io>2024-01-04 21:21:43 +0200
commit4e158f6bfa7d0747d8da70b3b15a44b52e35bb8a (patch)
tree84e20982138de5c9b6d319bf83ac79bd672f918f /src/corelib/tools/qsharedpointer.h
parente4391422574aa9aa89fece74f16c07c609cbbae2 (diff)
parenta13fd415d689be046c13cc562cbbbb5df0e6506a (diff)
Merge remote-tracking branch 'origin/tqtc/lts-5.15.13' into tqtc/lts-5.15-opensourcev5.15.13-lts-lgpl
Diffstat (limited to 'src/corelib/tools/qsharedpointer.h')
-rw-r--r--src/corelib/tools/qsharedpointer.h10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/corelib/tools/qsharedpointer.h b/src/corelib/tools/qsharedpointer.h
index 5d47369687..72e48d8a16 100644
--- a/src/corelib/tools/qsharedpointer.h
+++ b/src/corelib/tools/qsharedpointer.h
@@ -82,7 +82,12 @@ public:
QSharedPointer<T> &operator=(const QSharedPointer<T> &other);
QSharedPointer<T> &operator=(const QWeakPointer<T> &other);
- void swap(QSharedPointer<T> &other);
+ template <class X>
+ QSharedPointer(QSharedPointer<X> && other) noexcept;
+ template <class X>
+ QSharedPointer &operator=(QSharedPointer<X> && other) noexcept;
+
+ void swap(QSharedPointer<T> &other) noexcept;
QWeakPointer<T> toWeakRef() const;
@@ -104,6 +109,9 @@ public:
};
template <class T>
+size_t qHash(const QSharedPointer<T> &key, size_t seed = 0) noexcept;
+
+template <class T>
class QWeakPointer
{
public: