There were good reviews made after #31365 was merged, so this commit
addresses them separately.
1. Assert that the number is greater than zero
2. Use `constants` instead of calculating constants manually
3. Use `Const.bitCountAbs` for log2
74f361a5cehemisputnik committed on 3/1/2026, 7:34:17 PM· committed by Andrew Kelleyparentda6d4e2