Closed EugeneZelenko closed 4 years ago
I believe Wave is staying with C++03 for now. There are a lot of things we could be doing if that were loosened :) @hkaiser any thoughts?
I believe Wave is staying with C++03 for now. There are a lot of things we could be doing if that were loosened :) @hkaiser any thoughts?
I'm not sure what Boost's policy is nowadays. If it was for me, I had no objections to slowly migrating the codebase to something more modern (C++17)?
Alternatively - just related to the override
keyword - I would assume Boost will add a macro for this we could certainly use (or does is have already?).
This is not about changing language standard. Macro, introduced in boostorg/config#329, would expand as override
in C++11 or newer.
Ah, I see, that's great. I can take on making this update...
Are there other macros we should be using?
I think you should look on doc/macro_reference.qbk
or more readable formats generated from this file.
Looks like the actual macro is awaiting merge approval :) In the meantime I worked out a clang-tidy command line that does this for us:
clang-tidy -header-filter='.*hpp' -checks=-\*,modernize-use-override -config="{CheckOptions: [{key: modernize-use-override.OverrideSpelling, value: BOOST_OVERRIDE}, {key: modernize-use-override.IgnoreDestructors, value: 1}]}" -p build -fix include/boost/wave/cpp_exceptions.hpp
in case it is useful for others. Caveats:
compile_commands.json
in the "build" directory (change the -p
option to look elsewhere)BOOST_OVERRIDE
must already be defined or clang-tidy will silently fail to perform the editBOOST_OVERRIDE
was introduced in https://github.com/boostorg/config/commit/ffe4e0f5a448578cce14e3eed0cf7163333a81d9.
I found a few more places :)
Great! Thank you for so quick fix!
Complete list of warnings when Boost 1.72 is built with GCC 7.5 with
-Wsuggest-override
added tocxxflags
. Duplicated warnings from same location are omitted:Depends on boostorg/config#329.