diff options
Diffstat (limited to 'source/10-common/RcPtr.hpp')
-rw-r--r-- | source/10-common/RcPtr.hpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/source/10-common/RcPtr.hpp b/source/10-common/RcPtr.hpp index 130b2b2..e3e420e 100644 --- a/source/10-common/RcPtr.hpp +++ b/source/10-common/RcPtr.hpp @@ -15,7 +15,7 @@ public: uint32_t weakCount = 0; // TODO implement }; -template <class T, class TDeleter = DefaultDeleter<T>> +template <typename T, typename TDeleter = DefaultDeleter<T>> class RcPtr : TDeleter { private: static_assert(std::is_base_of_v<RefCounted, T>); @@ -78,7 +78,7 @@ public: return *this; } - template <class TBase> + template <typename TBase> requires std::is_base_of_v<TBase, T> operator RcPtr<TBase>() const { return RcPtr<TBase>(mPtr); @@ -96,7 +96,7 @@ public: return mPtr == ptr; } - template <class TThat> + template <typename TThat> bool operator==(const RcPtr<TThat>& ptr) const { return mPtr == ptr.Get(); } |