diff options
| author | Stanislaw Halik <sthalik@misaki.pl> | 2024-01-14 19:49:15 +0100 |
|---|---|---|
| committer | Stanislaw Halik <sthalik@misaki.pl> | 2024-01-14 19:49:15 +0100 |
| commit | 97fc4fcd50272dab1d2c6e94019502d42deb4a2c (patch) | |
| tree | cec5e6b6621ee5ad64dbb058bd1be3daca65e4b9 /serialize/packbits.hpp | |
| parent | 6c747d58f85d29987011d9519109928c3438fcef (diff) | |
a
Diffstat (limited to 'serialize/packbits.hpp')
| -rw-r--r-- | serialize/packbits.hpp | 17 |
1 files changed, 0 insertions, 17 deletions
diff --git a/serialize/packbits.hpp b/serialize/packbits.hpp index 527b7676..c94f96d7 100644 --- a/serialize/packbits.hpp +++ b/serialize/packbits.hpp @@ -11,24 +11,7 @@ template<std::unsigned_integral T, size_t N> struct Bits_; namespace floormat::detail_Pack { using namespace floormat::Pack; -template<std::unsigned_integral T, size_t Sum, typename... Xs> struct check_size_overflow; -template<std::unsigned_integral T, std::unsigned_integral U, size_t Sum, size_t N, typename... Xs> -struct check_size_overflow<T, Sum, Bits_<U, N>, Xs...> -{ - static_assert(std::is_same_v<T, U>); - static constexpr auto acc = Sum + size_t{N}; - using next_check = check_size_overflow<T, acc, Xs...>; - static constexpr auto size = next_check::size; - static constexpr bool result = next_check::result; -}; - -template<std::unsigned_integral T, size_t Sum> -struct check_size_overflow<T, Sum> -{ - static constexpr size_t size = Sum; - static constexpr bool result = Sum <= sizeof(T)*8; -}; template<std::unsigned_integral T, size_t CAPACITY> struct Storage |
