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

GHA: Linux: enforce the override keyword #9852

Closed
wants to merge 1 commit into from
Closed

Conversation

Al2Klimov
Copy link
Member

https://stackoverflow.com/a/29879000

If every method declares if it overrides something, mistakes leading to actually nothing being overridden don't happen.

If every method declares if it overrides something, mistakes leading to actually nothing being overridden don't happen.
@Al2Klimov Al2Klimov added the area/ci CI/CD label Aug 15, 2023
@cla-bot cla-bot bot added the cla/signed label Aug 15, 2023
@Al2Klimov
Copy link
Member Author

FAILED: lib/base/CMakeFiles/base.dir/application-environment.cpp.o 
/usr/local/Cellar/ccache/4.8.1/libexec/c++ -DBOOST_ASIO_USE_TS_EXECUTOR_AS_DEFAULT -DBOOST_COROUTINES_NO_DEPRECATION_WARNING -DBOOST_FILESYSTEM_NO_DEPRECATED -D_GNU_SOURCE -I/Users/aklimov/NET/WS/boost_1_66_0 -I/usr/local/Cellar/openssl@3/3.1.1/include -I/Users/aklimov/NET/WS/icinga2/third-party/nlohmann_json -I/Users/aklimov/NET/WS/icinga2/third-party/utf8cpp/source -I/Users/aklimov/NET/WS/icinga2 -I/Users/aklimov/NET/WS/icinga2/lib -I/Users/aklimov/NET/WS/icinga2/build-clion -I/Users/aklimov/NET/WS/icinga2/build-clion/lib -I/Users/aklimov/NET/WS/icinga2/third-party/execvpe -I/Users/aklimov/NET/WS/icinga2/third-party/mmatch -I/Users/aklimov/NET/WS/icinga2/third-party/socketpair -Werror=suggest-override -Qunused-arguments -fcolor-diagnostics -fno-limit-debug-info -pthread -Winvalid-pch -g -DI2_DEBUG -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX11.3.sdk -fcolor-diagnostics -std=c++17 -MD -MT lib/base/CMakeFiles/base.dir/application-environment.cpp.o -MF lib/base/CMakeFiles/base.dir/application-environment.cpp.o.d -o lib/base/CMakeFiles/base.dir/application-environment.cpp.o -c /Users/aklimov/NET/WS/icinga2/lib/base/application-environment.cpp
In file included from /Users/aklimov/NET/WS/icinga2/lib/base/application-environment.cpp:3:
In file included from /Users/aklimov/NET/WS/icinga2/lib/base/application.hpp:8:
In file included from /Users/aklimov/NET/WS/icinga2/build-clion/lib/base/application-ti.hpp:4:
In file included from /Users/aklimov/NET/WS/icinga2/lib/base/object.hpp:225:
In file included from /Users/aklimov/NET/WS/icinga2/lib/base/type.hpp:7:
In file included from /Users/aklimov/NET/WS/icinga2/lib/base/string.hpp:8:
In file included from /Users/aklimov/NET/WS/boost_1_66_0/boost/beast/core.hpp:15:
In file included from /Users/aklimov/NET/WS/boost_1_66_0/boost/beast/core/bind_handler.hpp:14:
In file included from /Users/aklimov/NET/WS/boost_1_66_0/boost/beast/core/type_traits.hpp:15:
In file included from /Users/aklimov/NET/WS/boost_1_66_0/boost/beast/core/detail/type_traits.hpp:13:
In file included from /Users/aklimov/NET/WS/boost_1_66_0/boost/beast/core/error.hpp:14:
/Users/aklimov/NET/WS/boost_1_66_0/boost/system/error_code.hpp:239:30: error: 'name' overrides a member function but is not marked 'override' [-Werror,-Wsuggest-override]
        virtual const char * name() const BOOST_NOEXCEPT
                             ^
/Library/Developer/CommandLineTools/SDKs/MacOSX11.3.sdk/usr/include/c++/v1/system_error:213:25: note: overridden virtual function is here
    virtual const char* name() const _NOEXCEPT = 0;
                        ^

🤷‍♂️

@Al2Klimov Al2Klimov closed this Aug 16, 2023
@icinga-probot icinga-probot bot deleted the Al2Klimov-patch-5 branch August 16, 2023 09:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant