mirror of
https://github.com/SFML/CSFML.git
synced 2026-10-27 13:36:12 +01:00
Use list(APPEND to append to lists
This commit is contained in:
1 parent
bb347c2c8c
commit
9f1619520e
1 file changed
+3
-4
@@ -62,8 +62,8 @@ function(set_file_warnings)
|
|||||||
endif()
|
endif()
|
||||||
|
|
||||||
if(WARNINGS_AS_ERRORS)
|
if(WARNINGS_AS_ERRORS)
|
||||||
set(CLANG_AND_GCC_WARNINGS ${CLANG_AND_GCC_WARNINGS} -Werror)
|
list(APPEND CLANG_AND_GCC_WARNINGS -Werror)
|
||||||
set(MSVC_WARNINGS ${MSVC_WARNINGS} /WX)
|
list(APPEND MSVC_WARNINGS /WX)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
set(CLANG_WARNINGS
|
set(CLANG_WARNINGS
|
||||||
@@ -82,8 +82,7 @@ function(set_file_warnings)
|
|||||||
# Don't enable -Wduplicated-branches for GCC < 8.1 since it will lead to false positives
|
# Don't enable -Wduplicated-branches for GCC < 8.1 since it will lead to false positives
|
||||||
# https://github.com/gcc-mirror/gcc/commit/6bebae75035889a4844eb4d32a695bebf412bcd7
|
# https://github.com/gcc-mirror/gcc/commit/6bebae75035889a4844eb4d32a695bebf412bcd7
|
||||||
if(CMAKE_CXX_COMPILER_VERSION VERSION_GREATER_EQUAL 8.1)
|
if(CMAKE_CXX_COMPILER_VERSION VERSION_GREATER_EQUAL 8.1)
|
||||||
set(GCC_WARNINGS
|
list(APPEND GCC_WARNINGS
|
||||||
${GCC_WARNINGS}
|
|
||||||
-Wduplicated-branches # warn if if / else branches have duplicated code
|
-Wduplicated-branches # warn if if / else branches have duplicated code
|
||||||
)
|
)
|
||||||
endif()
|
endif()
|
||||||
|
|||||||
Reference in new issue
Block a user