mirror of
https://github.com/libsdl-org/SDL.git
synced 2025-11-21 09:36:24 +00:00
cmake: add -Wimplicit-fallthrough warning
This commit is contained in:
committed by
Anonymous Maarten
parent
086a7a4687
commit
f59dbf6a12
@@ -105,6 +105,11 @@ function(SDL_AddCommonCompilerFlags TARGET)
|
||||
if(HAVE_GCC_WUNUSED_LOCAL_TYPEDEFS)
|
||||
sdl_target_compile_option_all_languages(${TARGET} "-Wno-unused-local-typedefs")
|
||||
endif()
|
||||
|
||||
check_c_compiler_flag(-Wimplicit-fallthrough HAVE_GCC_WIMPLICIT_FALLTHROUGH)
|
||||
if(HAVE_GCC_WIMPLICIT_FALLTHROUGH)
|
||||
sdl_target_compile_option_all_languages(${TARGET} "-Wimplicit-fallthrough")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if(SDL_WERROR)
|
||||
|
||||
Reference in New Issue
Block a user