Annotate intentional handler fallthrough
Co-authored-by: Andrew Kesterson <andrew@aklabs.net>
This commit is contained in:
@@ -263,6 +263,14 @@ foreach(_test IN LISTS AKERR_TESTS)
|
||||
endif()
|
||||
endforeach()
|
||||
|
||||
# HANDLE_GROUP deliberately enters the next case label. Keep that public macro
|
||||
# compiling with the warning enabled, so a future macro edit cannot restore the
|
||||
# warning for consumers which adopt -Wextra.
|
||||
if(CMAKE_C_COMPILER_ID MATCHES "GNU|Clang")
|
||||
target_compile_options(test_err_handle_group PRIVATE
|
||||
-Werror=implicit-fallthrough)
|
||||
endif()
|
||||
|
||||
set_tests_properties(
|
||||
${AKERR_WILL_FAIL_TESTS}
|
||||
PROPERTIES WILL_FAIL TRUE
|
||||
|
||||
Reference in New Issue
Block a user