Skip to content

Commit

Permalink
disable more warnings for msvc
Browse files Browse the repository at this point in the history
  • Loading branch information
yamt committed Aug 12, 2024
1 parent 5a2faca commit aec65a6
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions cmake/ToywasmConfig.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -321,6 +321,10 @@ if(CMAKE_C_COMPILER_ID STREQUAL "MSVC")
# C4820: 'exec_context': '7' bytes padding added after data member 'fast'
# C4996: '_open': This function or variable may be unsafe. Consider using _sopen_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} /Wall /WX /wd4018 /wd4061 /wd4100 /wd4127 /wd4146 /wd4189 /wd4206 /wd4242 /wd4244 /wd4245 /wd4267 /wd4296 /wd4310 /wd4388 /wd4389 /wd4820 /wd4996")
# C4701: otentially uninitialized local variable 'gt' used
# C4710: 'fabsf': function not inlined
# C5045: Compiler will insert Spectre mitigation for memory load if /Qspectre switch specified
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} /wd4701 /wd4710 /wd5045")
endif()
if(CMAKE_C_COMPILER_ID STREQUAL GNU)
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unknown-pragmas")
Expand Down

0 comments on commit aec65a6

Please sign in to comment.