diff options
Diffstat (limited to 'src/lib/util/coretmpl.h')
-rw-r--r-- | src/lib/util/coretmpl.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/lib/util/coretmpl.h b/src/lib/util/coretmpl.h index 55313a4a0f5..87f8cfbf09e 100644 --- a/src/lib/util/coretmpl.h +++ b/src/lib/util/coretmpl.h @@ -654,7 +654,7 @@ template <typename T, typename U, typename... V> constexpr T bitswap(T val, U b, /// bit of the input. Specify bits in the order they should appear in /// the output field, from most significant to least significant. /// \return The extracted bits packed into a right-aligned field. -template <unsigned B, typename T, typename... U> T bitswap(T val, U... b) noexcept +template <unsigned B, typename T, typename... U> constexpr T bitswap(T val, U... b) noexcept { static_assert(sizeof...(b) == B, "wrong number of bits"); static_assert((sizeof(std::remove_reference_t<T>) * 8) >= B, "return type too small for result"); |