Skip to content

Commit 2504268

Browse files
committed
Being more narrow.
1 parent a721b34 commit 2504268

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

tests/CMakeLists.txt

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,9 +33,10 @@ target_compile_definitions(supplemental-data INTERFACE SUPPLEMENTAL_TEST_DATA_DI
3333
function(fast_float_add_cpp_test TEST_NAME)
3434
add_executable(${TEST_NAME} ${TEST_NAME}.cpp)
3535
add_test(${TEST_NAME} ${TEST_NAME})
36-
if(WIN32)
36+
if(CMAKE_CXX_COMPILER_ID MATCHES "MSVC")
3737
target_compile_options(${TEST_NAME} PUBLIC /EHsc)
38-
else()
38+
endif()
39+
if(NOT WIN32)
3940
target_compile_options(${TEST_NAME} PUBLIC -Werror -Wall -Wextra -Weffc++)
4041
target_compile_options(${TEST_NAME} PUBLIC -Wsign-compare -Wshadow -Wwrite-strings -Wpointer-arith -Winit-self -Wconversion -Wsign-conversion)
4142
endif()

0 commit comments

Comments
 (0)