C++20 <bit> provides std::popcount, which is constexpr. However, it only supports unsigned types, so we probably would want to keep the name population_count as a wrapper that also handles signed types.
- relates to
-
JDK-8253387 Improve bit counting utilities using C++20 operations
-
- Closed
-