Skip to content

Commit 9907502

Browse files
committed
Add /permissive- flags with VS2017
1 parent d50c887 commit 9907502

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

cmake/modules/SwiftSharedCMakeConfig.cmake

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -279,6 +279,8 @@ macro(swift_common_cxx_warnings)
279279
# the repository for IDE features such as #pragma mark "Title".
280280
if("${CMAKE_C_COMPILER_ID}" STREQUAL "MSVC")
281281
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /wd4068")
282+
check_cxx_compiler_flag("/permissive-" CXX_SUPPORTS_PERMISSIVE_FLAG)
283+
append_if(CXX_SUPPORTS_PERMISSIVE_FLAG "/permissive-" CMAKE_CXX_FLAGS)
282284
endif()
283285

284286
# Disallow calls to objc_msgSend() with no function pointer cast.

0 commit comments

Comments
 (0)