37template <
typename T,
typename... Remaining>
40 Remaining... remaining_values)
noexcept {
41 if constexpr (
sizeof(T) == 1U) {
42 buffer[0] =
static_cast<unsigned char>(value);
44 if constexpr (
sizeof...(Remaining) == 0U) {
47 to_big_endian(&value, buffer.template sub_buffer<0U,
sizeof(T)>());
50 if constexpr (
sizeof...(Remaining) > 0U) {
52 buffer.template sub_buffer<
sizeof(T)>(), remaining_values...);
Class of views of mutable buffers with static sizes.
Definition of mutable_static_binary_view class.
Namespace of internal implementations.
void pack_in_big_endian(mutable_static_binary_view< total_size_of< T, Remaining... > > buffer, T value, Remaining... remaining_values) noexcept
Pack some values in big endian.
constexpr std::size_t total_size_of
Get the total size of types in template arguments.
void to_big_endian(const void *from, mutable_static_binary_view< N > to) noexcept
Convert to big endian.
Definition of to_big_endian function.
Definition of total_size_of variable.