-
-
Notifications
You must be signed in to change notification settings - Fork 649
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
clang warnings when using C++11 or newer #42
Comments
strange - which clang compiler (version) are you using? Which OS? on travis I build all the examples with Are you using - c++11? Can you give me a minimal sample program that reproduces the warning? |
I am using c++14 and have also seen it with c++11. The factorial example in the tutorial will report the warning if compiled with It will also give
I also see the warnings with clang on the Mac which is at Apple version 8.0.0 |
I indeed reproduced this - as can be seen here Changing to c++98 removes these errors. I will investigate. Thanks for the report! EDIT: updated permalink to wandbox compiler |
I had tested for warnings with C++11/14 only with GCC... should have tried with clang as well. Perhaps I should add c++11 builds on the CI as well. See my related stack overflow question |
Clang complains about Result and Subcase requiring implicit copy constructors when they have user defined destructors (deprecated in C++11).
doctest/doctest.h:727:9: warning: definition of implicit copy constructor for 'Result' is deprecated because it has a user-declared destructor [-Wdeprecated]
...
doctest/doctest.h:847:89: note: implicit copy constructor for 'Result' first required here template <typename R> Result operator==(const DOCTEST_REF_WRAP(R) rhs) { return Result(lhs == rhs, stringifyBinaryExpr(lhs, " == ", rhs)); }
doctest/doctest.h:2312:14: warning: definition of implicit copy constructor for 'Subcase' is deprecated because it has a user-declared destructor [-Wdeprecated]
...This one was caused by pushing a Subcase onto a vector (line 2303).
The text was updated successfully, but these errors were encountered: