From 1308e2b935f6ef0451686336192b6502fdeccb9e Mon Sep 17 00:00:00 2001 From: Zephyron Date: Mon, 3 Mar 2025 16:35:57 +1000 Subject: [PATCH] CMake: Enable C++ latest and coroutines for MSVC builds Add /std:c++latest and /await compiler flags for MSVC builds to enable the latest C++ features and coroutine support. --- CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 542fce810..e35fec4df 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -14,7 +14,7 @@ include(CTest) # Disable Warnings as Errors for MSVC if (MSVC) - set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /W3 /WX-") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /W3 /WX- /std:c++latest /await") endif() # Check if SDL2::SDL2 target exists; if not, create an alias