mirror of
https://github.com/TerryCavanagh/VVVVVV.git
synced 2026-01-29 17:38:16 +03:00
Fix wrong comment on disabling MSVC exceptions
`/EHsc` does not actually disable exceptions on MSVC, it only makes the compiler assume that `extern "C"` functions never throw C++ exceptions. We had a discussion on Discord about actually disabling exceptions, and from research, that requires defining `_HAS_EXCEPTIONS=0`, but it's unsupported and undocumented so we deemed the benefits not worth it. Thus, we will stay with `/EHsc`. But the comment still has to be updated. [skip ci]
This commit is contained in:
@@ -287,7 +287,8 @@ endif()
|
||||
if(MSVC)
|
||||
# MSVC doesn't have /std:c99 or /std:c++98 switches!
|
||||
|
||||
# Disable exceptions
|
||||
# MSVC does not officially support disabling exceptions,
|
||||
# so this is as far as we are willing to go to disable them.
|
||||
string(REGEX REPLACE "/EH[a-z]+" "" CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS}")
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /EHsc")
|
||||
|
||||
|
||||
Reference in New Issue
Block a user