Function population_count

Synopsis

#include "breeze/mathematics/population_count.hpp"

template <typename T>
constexpr int population_count(T t) noexcept

Description

Returns
The number of on bits in the binary representation of the value of t. T must be an unsigned integral type.
Warning
[FUTURE] This function template will be removed in favor of std::popcount() when Breeze will require C++20.

Mentioned in

Source

Line 32 in breeze/mathematics/population_count.hpp.