-
Notifications
You must be signed in to change notification settings - Fork 226
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix rounding for non-representable numbers #968
Conversation
@jzmaddock any idea why this would break the use of pre-compiled headers under MSVC? See: https://github.com/boostorg/math/actions/runs/4447933117/jobs/7810069256?pr=968#step:11:523 |
No... I wonder if there are any unrelated changes effecting us - build system? BTW I can't help thinking there may be a simpler solution, let me have a think. |
The failure is now |
Ah.... the test case is wrong: it assumes that the boundary case on 2^d where there are d digits in the long long is always an integer, as is So... I guess either only test floats that have fewer digits than the integer type - since that is the bug case - or else we need to figure out how to fix the test case. The latter might be tricky, since we're basically duplicating the functionality of llround to carry out the test! So I'd favour the former for now? |
The PCH issues are likely related to recent changes in B2. I have opened an issue with them: bfgroup/b2#229 |
@jzmaddock Can you take a look at this now that it's green? The context switching for constexpr calculation is more verbose than I had hoped. |
Thanks for this Matt: other than the two minor comments looks good to me! |
Partially addresses re-raised #430. Once CI validates this fix works for
llround
will propagate to the rest of the functions.