The struct OnesCount is replaced with the constexpr function template onesCount().