Skip to content

Commit

Permalink
exclude -Wshorten-64-to-32 checks for clang builds
Browse files Browse the repository at this point in the history
Signed-off-by: Rui Chen <rui@chenrui.dev>
  • Loading branch information
chenrui333 committed Feb 17, 2024
1 parent 4eafbb2 commit d742e75
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion cmake/modules/c_flags.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,9 @@ add_cflag_if_supported("-Wformat")
add_cflag_if_supported("-Wformat-security")
add_cflag_if_supported("-Wmaybe-uninitialized")
add_cflag_if_supported("-Wmissing-variable-declarations")
add_cflag_if_supported("-Wshorten-64-to-32")
if(NOT CMAKE_C_COMPILER_ID MATCHES "Clang")
add_cflag_if_supported("-Wshorten-64-to-32")
endif()
add_cflag_if_supported("-Wimplicit-function-declaration")

##
Expand Down

0 comments on commit d742e75

Please sign in to comment.