Skip to content

Commit 4c73b57

Browse files
authored
Merge pull request #364 from qw-ctf/win-warn
WIN: Disable some opinionated msvc warnings.
2 parents ea92a73 + ff005e2 commit 4c73b57

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

CMakeLists.txt

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,11 @@ if(FTESV)
153153
endif()
154154
# If not Miscrosoft compilator - then set additional options for linker.
155155
if (CMAKE_C_COMPILER_ID STREQUAL "MSVC")
156-
target_compile_options(${PROJECT_NAME} PRIVATE /W4)
156+
# 4100 - unused parameter
157+
# 4210 - using extern keyword in functions
158+
# 4456 - shadowing locals, broadly used
159+
# 4459 - shadowing globals, broadly used
160+
target_compile_options(${PROJECT_NAME} PRIVATE /W4 /wd4100 /wd4210 /wd4456 /wd4459)
157161
else()
158162
target_compile_options(${PROJECT_NAME} PRIVATE -Wall)
159163

0 commit comments

Comments
 (0)