1
0
Fork 0
mirror of https://github.com/Neargye/magic_enum.git synced 2026-01-09 23:34:23 +00:00
This commit is contained in:
neargye 2020-07-06 19:22:53 +05:00
parent 13eff83de5
commit 573bc60011
2 changed files with 3 additions and 4 deletions

View file

@ -210,7 +210,7 @@ constexpr std::uint8_t log2(T value) noexcept {
return log2<U>(static_cast<U>(value));
} else {
auto ret = std::uint8_t{0};
for (; value > static_cast<T>(1U); value >>= static_cast<T>(1U), ++ret) {};
for (; value > static_cast<T>(1); value >>= static_cast<T>(1), ++ret) {};
return ret;
}