diff --git a/src/entt/core/bit.hpp b/src/entt/core/bit.hpp index 4f5b24b0a..442d168a7 100644 --- a/src/entt/core/bit.hpp +++ b/src/entt/core/bit.hpp @@ -62,7 +62,7 @@ template template [[nodiscard]] constexpr std::enable_if_t, Type> fast_mod(const Type value, const std::size_t mod) noexcept { ENTT_ASSERT_CONSTEXPR(has_single_bit(mod), "Value must be a power of two"); - return value & (mod - 1u); + return static_cast(value & (mod - 1u)); } } // namespace entt