Reinstate staticcasts.
This commit is contained in:
committed by
Matthew Parkinson
parent
0728db1413
commit
dc36849dd0
@@ -76,11 +76,11 @@ namespace snmalloc
|
|||||||
#else
|
#else
|
||||||
if constexpr (std::is_same_v<unsigned long, std::size_t>)
|
if constexpr (std::is_same_v<unsigned long, std::size_t>)
|
||||||
{
|
{
|
||||||
return __builtin_clzl(x);
|
return static_cast<size_t>(__builtin_clzl(x));
|
||||||
}
|
}
|
||||||
else if constexpr (std::is_same_v<unsigned long long, std::size_t>)
|
else if constexpr (std::is_same_v<unsigned long long, std::size_t>)
|
||||||
{
|
{
|
||||||
return __builtin_clzll(x);
|
return static_cast<size_t>(__builtin_clzll(x));
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
@@ -153,11 +153,11 @@ namespace snmalloc
|
|||||||
#else
|
#else
|
||||||
if constexpr (std::is_same_v<unsigned long, std::size_t>)
|
if constexpr (std::is_same_v<unsigned long, std::size_t>)
|
||||||
{
|
{
|
||||||
return __builtin_ctzl(x);
|
return static_cast<size_t>(__builtin_ctzl(x));
|
||||||
}
|
}
|
||||||
else if constexpr (std::is_same_v<unsigned long long, std::size_t>)
|
else if constexpr (std::is_same_v<unsigned long long, std::size_t>)
|
||||||
{
|
{
|
||||||
return __builtin_ctzll(x);
|
return static_cast<size_t>(__builtin_ctzll(x));
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user