-
Notifications
You must be signed in to change notification settings - Fork 273
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
Replace asserts with INVARIANT et al. to enable compilation with NDEBUG #1536
Replace asserts with INVARIANT et al. to enable compilation with NDEBUG #1536
Conversation
for src and unit tests with gcc and clang.
The unit test is probably best converted to Catch if we're going to mess with it -- that shouldn't mean much more than removing the driver The remove-return change looks reasonable, but rather than do half a job let's replace the other 8 asserts in that file if we're doing one. |
The point of the PR is to enable a CI build with disabled assertions/invariants etc. Converting the unit test to Catch is out of scope. The same holds for the change to remove_returns.cpp: it fails to compile with clang++ -DNDEBUG, this PR fixes that. Changing assertions to invariants everywhere is worth doing, but not the purpose of this PR. |
I agree. This PR is now obsolete. |
Great, I will ping you when they are merged (hopefully hours not days :)) Would you mind checking that the build is successful with develop+1537+1538 in your configuration? |
@andreast271 those two are both now merged; latest develop should work as you intend. |
@smowton thank you very much. I replied to your comment from 10:50 GMT because I saw a problem. I guess you never got that message ... |
I don't see anything here between my comment 10:50 and my comment 13:15, no. Repeat it? |
The changes in this PR are needed:
clang discovered an instance of an unused variable that had been ignored by gcc in
remove_returns.cpp
.