Skip to content
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

Add more warnings to W3 #2048

Merged
merged 1 commit into from
Aug 5, 2024
Merged

Add more warnings to W3 #2048

merged 1 commit into from
Aug 5, 2024

Conversation

sweemer
Copy link
Contributor

@sweemer sweemer commented Aug 3, 2024

These two warnings are not enabled by default at the W3 level, but they are nice to have in the CI so I have added them.

@coveralls
Copy link

coveralls commented Aug 3, 2024

Coverage Status

coverage: 72.642%. remained the same
when pulling 638cbf2 on sweemer:more-w3
into 0e83ab7 on lballabio:master.

@lballabio
Copy link
Owner

Agreed that they're nice to have in the CI, but we might think about adding them in the CI builds and not as defaults. I'm thinking of the people that might be modifying the sources, or adding to them; we might be triggering warnings in their code that they might not want to deal with right now. It's probably not a lot of people, though.

ql/time/ecb.cpp Outdated
@@ -304,13 +304,6 @@ namespace QuantLib {
incrementAndCheckForOverlow(nextCodeStr[3]);
}
return nextCodeStr;
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think the right fix is to remove this early return and leave the extra check below.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed

@sweemer
Copy link
Contributor Author

sweemer commented Aug 5, 2024

Agreed that they're nice to have in the CI, but we might think about adding them in the CI builds and not as defaults. I'm thinking of the people that might be modifying the sources, or adding to them; we might be triggering warnings in their code that they might not want to deal with right now. It's probably not a lot of people, though.

As far as I understand, the CI warnings should all be enabled when QL_ENABLE_DEFAULT_WARNING_LEVEL is on, in order to ensure consistency with the CI. People who turn this option off will only see compiler warnings enabled, which is the W1 level for MSVC. So adding this warning to the W3 level should not affect those users.

@lballabio lballabio added this to the Release 1.36 milestone Aug 5, 2024
@lballabio lballabio merged commit 2243398 into lballabio:master Aug 5, 2024
42 checks passed
@sweemer sweemer deleted the more-w3 branch August 5, 2024 10:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants