Thread (80 messages) 80 messages, 5 authors, 2019-06-25
STALE2555d

[PATCH 14/17] msvc: add pragmas for common warnings

From: Philip Oakley via GitGitGadget <hidden>
Date: 2019-06-18 12:24:15
Subsystem: the rest · Maintainer: Linus Torvalds

From: Philip Oakley <redacted>

MSVC can be overzealous about some warnings. Disable them.

Signed-off-by: Philip Oakley <redacted>
Signed-off-by: Johannes Schindelin <redacted>
---
 compat/msvc.h | 4 ++++
 1 file changed, 4 insertions(+)
diff --git a/compat/msvc.h b/compat/msvc.h
index d7525cf61d..1d7a8c6145 100644
--- a/compat/msvc.h
+++ b/compat/msvc.h
@@ -6,6 +6,10 @@
 #include <malloc.h>
 #include <io.h>
 
+#pragma warning(disable: 4018) /* signed/unsigned comparison */
+#pragma warning(disable: 4244) /* type conversion, possible loss of data */
+#pragma warning(disable: 4090) /* 'function' : different 'const' qualifiers (ALLOC_GROW etc.)*/
+
 /* porting function */
 #define inline __inline
 #define __inline__ __inline
-- 
gitgitgadget
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help