You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Expansion: an rvalue of type decimal64 equal to the maximum finite number that can
be represented by an object of type decimal64; exactly equal to 9.999999999999999 x 10^384 (there are fifteen 9's after the decimal point)
This is just for decimal64, others have same issue.
I think adding test that uses "excessive" precision(e.g. std::print("max: {:.30e}\n", nl::max()); ) to print numeric limits might be useful since I literally copy/pasted the value from PDF(
9.999999999999999) into find of my output window and I saw that after fix above output matches(all digits after those nines were zero and exponent matched).
The text was updated successfully, but these errors were encountered:
I could be wrong, but it seems to be a bug.
When I do:
I get correct value:
max: 9.99999999999999900000e+384
with original code I get infinity.
by correct I mean what https://www.open-std.org/JTC1/SC22/WG21/docs/papers/2009/n2849.pdf specifies:
This is just for decimal64, others have same issue.
I think adding test that uses "excessive" precision(e.g.
std::print("max: {:.30e}\n", nl::max());
) to print numeric limits might be useful since I literally copy/pasted the value from PDF(9.999999999999999) into find of my output window and I saw that after fix above output matches(all digits after those nines were zero and exponent matched).
The text was updated successfully, but these errors were encountered: