11 #ifndef TLX_MATH_ROUND_TO_POWER_OF_TWO_HEADER 12 #define TLX_MATH_ROUND_TO_POWER_OF_TWO_HEADER 24 template <
typename Integral>
27 for (
size_t k = 1; k != 8 *
sizeof(n); k <<= 1) {
106 #endif // !TLX_MATH_ROUND_TO_POWER_OF_TWO_HEADER
static int round_down_to_power_of_two(int i)
does what it says: round down to next power of two
static int round_up_to_power_of_two(int i)
does what it says: round up to next power of two
static Integral round_up_to_power_of_two_template(Integral n)