mirror of
https://github.com/holub/mame
synced 2025-06-05 20:33:45 +03:00
util/coretmpl.h: Fixed clang narrowing warning.
This commit is contained in:
parent
467b4615f6
commit
a5e466717f
@ -627,7 +627,7 @@ template <typename T, typename U, typename V> constexpr T BIT(T x, U n, V w)
|
||||
/// \return The extracted bits packed into a right-aligned field.
|
||||
template <typename T, typename U, typename... V> constexpr T bitswap(T val, U b, V... c) noexcept
|
||||
{
|
||||
if constexpr (sizeof...(c))
|
||||
if constexpr (sizeof...(c) > 0U)
|
||||
return (BIT(val, b) << sizeof...(c)) | bitswap(val, c...);
|
||||
else
|
||||
return BIT(val, b);
|
||||
|
Loading…
Reference in New Issue
Block a user