diff --git a/src/lib/util/coretmpl.h b/src/lib/util/coretmpl.h index 49f01f8415c..9d033f72d26 100644 --- a/src/lib/util/coretmpl.h +++ b/src/lib/util/coretmpl.h @@ -627,7 +627,7 @@ template constexpr T BIT(T x, U n, V w) /// \return The extracted bits packed into a right-aligned field. template 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);