8000 Merge pull request #7114 from pks-gitlab/pks-msvc-different-enum-warn… · libgit2/libgit2@9d5f1ba · GitHub
[go: up one dir, main page]

Skip to content

Commit 9d5f1ba

Browse files
authored
Merge pull request #7114 from pks-gitlab/pks-msvc-different-enum-warnings
cmake: disable warnings for operands with different enum types
2 parents 5ab90d3 + 5d78d63 commit 9d5f1ba

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

cmake/DefaultCFlags.cmake

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,9 @@ if(MSVC)
1313
# /Gd - explicitly set cdecl calling convention
1414
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} /Gd")
1515

16+
# Remove warnings about operands that use different enum types.
17+
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} /wd5287")
18+
1619
if(NOT (MSVC_VERSION LESS 1900))
1720
# /guard:cf - Enable Control Flow Guard
1821
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} /guard:cf")

0 commit comments

Comments
 (0)
0