-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
CMake: Enable -Wfloat-conversion warnings #3129
CMake: Enable -Wfloat-conversion warnings #3129
Conversation
Ping. Please have a look at the unmerged PRs linked above so that we can merge this. I hope this will avoid introducing new unintended-precision-loss bugs like #3119. |
6187491
to
56b9bc0
Compare
I rebased on latest 2.3, we still have a few warnings. EDIT: Just two commits, added them here. |
56b9bc0
to
4a8461f
Compare
int currentPosition = m_waveformRenderer->getPlayPosVSample(); | ||
int totalSamples = m_waveformRenderer->getTotalVSample(); | ||
int currentPosition = static_cast<int>(m_waveformRenderer->getPlayPosVSample()); | ||
int totalSamples = static_cast<int>(m_waveformRenderer->getTotalVSample()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ups sorry. you have hit a rats nest.
getPlayPosVSample() should directly return int, because it is the already rounded VSample.
However I think we have some rounding issues here, because m_visualSamplePerPixel is double and can be changed in fine steps since we have removed the stepping from waveform zooms.
I think we need to review all position calculations.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done, see #3176.
4a8461f
to
34d0c9f
Compare
Ready after rebasing? |
34d0c9f
to
2fa3102
Compare
Mixxx is now warning-free on my machine. Let's check if the CI agrees. |
We have now a failing test on MSVC: The following tests FAILED: |
This is unrelated to this PR. It only changes the compiler warnings, no actual code. But I can look into it, although it will be hard to debug with remote debugging via CI. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
I also noticed the recent test failures on AppVeyor for Windows that must be caused by some other changes. Unfortunately, we are not able to distinguish those actual failures from spurious failures as long as the tests are not reliable. |
@daschuer Merge? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok, right, let's merge.
Requires the following PRs to be merged: