|
|
◆ set_bits_with_int()
| constexpr void set_bits_with_int |
( |
T_Type & |
integer, |
|
|
UST |
index, |
|
|
UST |
value |
|
) |
| |
|
constexprnoexcept |
Set multiple consecutive bits of an unsigned integer using the bit pattern of another integer value.
- Template Parameters
-
| t_num_bits | Number of bits that should be set. Values of the source integer value that can't be represented by the provided number of bits will trigger an assertion |
| t_clear_bits | If false, already set bits won't be cleared to match the source integers bit pattern. |
| T_Type | An unsigned integer type |
- Parameters
-
| [in,out] | integer | The integer that should be modified |
| [in] | index | The index of the first bit that should be modified |
| [in] | value | The source integer |
|