From 96a101310f6343b6e3e3903b3a7e7301eb8cdfb1 Mon Sep 17 00:00:00 2001 From: Marcus Holland-Moritz Date: Tue, 11 Jul 2023 01:20:42 +0200 Subject: [PATCH] Make sure MSVC correctly defines __cplusplus --- CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 255d7e67..2fd4275c 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -96,7 +96,7 @@ elseif("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang") endif() if(CMAKE_CXX_COMPILER_ID STREQUAL "MSVC") - add_compile_options(/utf-8 /wd4267 /wd4244 /wd5219) + add_compile_options(/Zc:__cplusplus /utf-8 /wd4267 /wd4244 /wd5219) endif() if(CMAKE_CXX_COMPILER_ID STREQUAL "AppleClang")