Perhaps nicer to avoid the comment and write:
const C1 = 505054698555331 // floor(2^64*4/146097)
constexpr int C1 = floor(2^64*4/146097);
std::floor was made constexpr in C++23, which is pretty recent as far as C++ standards go. It's possible the author didn't think using C++23 was worth the constraints it places on who could use the code.
std::floor was made constexpr in C++23, which is pretty recent as far as C++ standards go. It's possible the author didn't think using C++23 was worth the constraints it places on who could use the code.