Template Function Rose::BitOps::position

Template Function Rose::BitOps::position#

Function Documentation#

template<typename Unsigned>
inline Unsigned Rose::BitOps::position(size_t i)#

Generate a single-bit mask.

Returns a value that has all bit cleared except the bit at position i. If i is outside the valid range of bit positions for the unsigned type, then zero is returned.