diff options
author | Tarja Sundqvist <tarja.sundqvist@qt.io> | 2024-01-04 21:21:43 +0200 |
---|---|---|
committer | Tarja Sundqvist <tarja.sundqvist@qt.io> | 2024-01-04 21:21:43 +0200 |
commit | 4e158f6bfa7d0747d8da70b3b15a44b52e35bb8a (patch) | |
tree | 84e20982138de5c9b6d319bf83ac79bd672f918f /src/corelib/tools/qsharedpointer.h | |
parent | e4391422574aa9aa89fece74f16c07c609cbbae2 (diff) | |
parent | a13fd415d689be046c13cc562cbbbb5df0e6506a (diff) |
Merge remote-tracking branch 'origin/tqtc/lts-5.15.13' into tqtc/lts-5.15-opensourcev5.15.13-lts-lgpl
Change-Id: Ie9df84af22570d601db002e391a1a0d97e7cd9e1
Diffstat (limited to 'src/corelib/tools/qsharedpointer.h')
-rw-r--r-- | src/corelib/tools/qsharedpointer.h | 10 |
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: |