struct Bitfield::Element

Declaration

template <typename T,
          unsigned int Offset,
          unsigned int Size,
          T MaxValue = std::is_enum<type - parameter - 0 - 0>::value
                           ? type - parameter - 0 - 0(0)
                           : std::numeric_limits<type - parameter -
                                                 0 - 0>::max()>
struct Bitfield::Element { /* full declaration omitted */ };

Description

Describes an element of a Bitfield. This type is then used with the Bitfield static member functions.

Declared at: llvm/include/llvm/ADT/Bitfields.h:223

Templates

T
The type of the field once in unpacked form.
unsigned int Offset
The position of the first bit.
unsigned int Size
The size of the field.
T MaxValue = std::is_enum<type-parameter-0-0>::value ? type-parameter-0-0(0) : std::numeric_limits<type-parameter-0-0>::max()
For enums the maximum enum allowed.

Member Variables

public static const unsigned int Shift = Offset
public static const unsigned int Bits = Size
public static const unsigned int FirstBit = Offset
public static const unsigned int LastBit = Shift + Bits - 1
public static const unsigned int NextBit = Shift + Bits
private static const size_t TypeBits = sizeof(typename ResolveUnderlyingType<type-parameter-0-0, std::is_enum<type-parameter-0-0>::value>::type) * 8
private static const llvm::Bitfield::Element::IntegerType UserMaxValue = static_cast<typename ResolveUnderlyingType<type-parameter-0-0, std::is_enum<type-parameter-0-0>::value>::type>(MaxValue)