1
0
mirror of https://github.com/Kitware/CMake.git synced 2025-10-14 02:08:27 +08:00

CSharp: Set C# compiler to default version

Remove the hard-coded ``/langversion:3`` option and let the compiler
choose the default language version automatically as documented at

    https://docs.microsoft.com/en-us/dotnet/csharp/language-reference/configure-language-version

Fixes: #17674
This commit is contained in:
Sumit Bhardwaj
2020-01-15 17:09:16 -08:00
committed by Brad King
parent e125d50ddf
commit 2e882b4275

View File

@@ -10,7 +10,7 @@ get_filename_component(CMAKE_BASE_NAME "${CMAKE_CSharp_COMPILER}" NAME_WE)
set(CMAKE_BUILD_TYPE_INIT Debug)
set(CMAKE_CSharp_FLAGS_INIT "/define:TRACE /langversion:3")
set(CMAKE_CSharp_FLAGS_INIT "/define:TRACE")
set(CMAKE_CSharp_FLAGS_DEBUG_INIT "/debug:full /optimize- /warn:3 /errorreport:prompt /define:DEBUG")
set(CMAKE_CSharp_FLAGS_RELEASE_INIT "/debug:none /optimize /warn:1 /errorreport:queue")
set(CMAKE_CSharp_FLAGS_RELWITHDEBINFO_INIT "/debug:full /optimize-")