Nugget
Loading...
Searching...
No Matches
Public Types | Static Public Attributes | List of all members
Utilities::BitSpan< T, width > Struct Template Reference

A bit field element to be used in a BitField. More...

#include <common/util/bitfield.hh>

Public Types

using Type = T
 
using Underlying = std::conditional_t< std::is_enum_v< T >, std::underlying_type_t< std::conditional_t< std::is_enum_v< T >, T, BitFieldInternal::Dummy > >, T >
 

Static Public Attributes

static constexpr unsigned Width = width
 

Detailed Description

template<BitFieldInternal::IntegralLike T, unsigned width = BitFieldInternal::DefaultBitSize<T>::size>
struct Utilities::BitSpan< T, width >

A bit field element to be used in a BitField.

Template Parameters
TThe type of the field. This can be any integral type or enum type.
widthThe width of the field in bits.

Member Typedef Documentation

◆ Type

template<BitFieldInternal::IntegralLike T, unsigned width = BitFieldInternal::DefaultBitSize<T>::size>
using Utilities::BitSpan< T, width >::Type = T

◆ Underlying

template<BitFieldInternal::IntegralLike T, unsigned width = BitFieldInternal::DefaultBitSize<T>::size>
using Utilities::BitSpan< T, width >::Underlying = std::conditional_t<std::is_enum_v<T>, std::underlying_type_t<std::conditional_t<std::is_enum_v<T>, T, BitFieldInternal::Dummy> >, T>

Member Data Documentation

◆ Width

template<BitFieldInternal::IntegralLike T, unsigned width = BitFieldInternal::DefaultBitSize<T>::size>
constexpr unsigned Utilities::BitSpan< T, width >::Width = width
staticconstexpr

The documentation for this struct was generated from the following file: