Use /W4 in format-test and only if FMT_EXTRA_TESTS is set
as (1) we don't want to force /W4 on users of the library and (2) some of the warnings only show up when the formatting functions are used.
This commit is contained in:
@@ -83,8 +83,6 @@ add_library(format ${FMT_SOURCES})
|
||||
if (CMAKE_COMPILER_IS_GNUCXX)
|
||||
set_target_properties(format PROPERTIES COMPILE_FLAGS
|
||||
"-Wall -Wextra -Wshadow -pedantic")
|
||||
elseif (MSVC)
|
||||
set_target_properties(format PROPERTIES COMPILE_FLAGS /W4)
|
||||
endif ()
|
||||
|
||||
# If FMT_EXTRA_TESTS is TRUE, then test compilation with both -std=c++11
|
||||
|
||||
Reference in New Issue
Block a user