Skip to content

Commit 19e413d

Browse files
committed
Added -Wsuggest-override to the warning list
This warning is available on GCC since 5.1 and Clang since 11.0.0. Since GCC 9.2 it also does not warn if 'final' is used instead of 'override'. This was the case in Clang since the warning was introduced.
1 parent d19d892 commit 19e413d

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

cmake/CompilerWarnings.cmake

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,7 @@ function(
5656
-Wdouble-promotion # warn if float is implicit promoted to double
5757
-Wformat=2 # warn on security issues around functions that format output (ie printf)
5858
-Wimplicit-fallthrough # warn on statements that fallthrough without an explicit annotation
59+
-Wsuggest-override # warn if an overridden member function is not marked 'override' or 'final'
5960
)
6061
endif()
6162

0 commit comments

Comments
 (0)