diff options
Diffstat (limited to '')
-rw-r--r-- | src/common/intrusive_red_black_tree.h | 28 |
1 files changed, 11 insertions, 17 deletions
diff --git a/src/common/intrusive_red_black_tree.h b/src/common/intrusive_red_black_tree.h index 93046615e..bc2940fa0 100644 --- a/src/common/intrusive_red_black_tree.h +++ b/src/common/intrusive_red_black_tree.h @@ -96,10 +96,6 @@ public: return m_node == rhs.m_node; } - constexpr bool operator!=(const Iterator& rhs) const { - return !(*this == rhs); - } - constexpr pointer operator->() const { return m_node; } @@ -242,19 +238,21 @@ public: template <typename T> concept HasRedBlackKeyType = requires { - { std::is_same<typename T::RedBlackKeyType, void>::value } -> std::convertible_to<bool>; -}; + { + std::is_same<typename T::RedBlackKeyType, void>::value + } -> std::convertible_to<bool>; + }; namespace impl { - template <typename T, typename Default> - consteval auto* GetRedBlackKeyType() { - if constexpr (HasRedBlackKeyType<T>) { - return static_cast<typename T::RedBlackKeyType*>(nullptr); - } else { - return static_cast<Default*>(nullptr); - } +template <typename T, typename Default> +consteval auto* GetRedBlackKeyType() { + if constexpr (HasRedBlackKeyType<T>) { + return static_cast<typename T::RedBlackKeyType*>(nullptr); + } else { + return static_cast<Default*>(nullptr); } +} } // namespace impl @@ -322,10 +320,6 @@ public: return m_impl == rhs.m_impl; } - constexpr bool operator!=(const Iterator& rhs) const { - return !(*this == rhs); - } - constexpr pointer operator->() const { return Traits::GetParent(std::addressof(*m_impl)); } |