Michele Caini 4 лет назад
Родитель
Сommit
49e702c0c7
1 измененных файлов с 2 добавлено и 2 удалено
  1. 2 2
      src/entt/core/hashed_string.hpp

+ 2 - 2
src/entt/core/hashed_string.hpp

@@ -244,7 +244,7 @@ template<typename Char>
  */
 template<typename Char>
 [[nodiscard]] constexpr bool operator<=(const basic_hashed_string<Char> &lhs, const basic_hashed_string<Char> &rhs) ENTT_NOEXCEPT {
-    return lhs.value() <= rhs.value();
+    return !(rhs < lhs);
 }
 
 /**
@@ -257,7 +257,7 @@ template<typename Char>
  */
 template<typename Char>
 [[nodiscard]] constexpr bool operator>(const basic_hashed_string<Char> &lhs, const basic_hashed_string<Char> &rhs) ENTT_NOEXCEPT {
-    return !(lhs <= rhs);
+    return rhs < lhs;
 }
 
 /**