diff options
author | Yann Collet <cyan@fb.com> | 2020-11-15 00:24:36 (GMT) |
---|---|---|
committer | Yann Collet <cyan@fb.com> | 2020-11-15 00:27:57 (GMT) |
commit | e0f85f2fc8e8868b2623a5344781f269bda7d4ba (patch) | |
tree | 362c2dda28e611c7110c80a4c2ad3d67ae466407 /lib | |
parent | 468011c346a1e73eede3e70ee8009f812b02cc76 (diff) | |
download | lz4-e0f85f2fc8e8868b2623a5344781f269bda7d4ba.zip lz4-e0f85f2fc8e8868b2623a5344781f269bda7d4ba.tar.gz lz4-e0f85f2fc8e8868b2623a5344781f269bda7d4ba.tar.bz2 |
better visual conformance
only include <intrin.h> on vs2005+ (#947)
remove some useless #pragma
fix a few minor Visual warnings
Diffstat (limited to 'lib')
-rw-r--r-- | lib/lz4.c | 7 |
1 files changed, 3 insertions, 4 deletions
@@ -121,10 +121,9 @@ /*-************************************ * Compiler Options **************************************/ -#ifdef _MSC_VER /* Visual Studio */ -# include <intrin.h> -# pragma warning(disable : 4127) /* disable: C4127: conditional expression is constant */ -# pragma warning(disable : 4293) /* disable: C4293: too large shift (32-bits) */ +#if defined(_MSC_VER) && (_MSC_VER >= 1400) /* Visual Studio 2005+ */ +# include <intrin.h> /* only present in VS2005+ */ +# pragma warning(disable : 4127) /* disable: C4127: conditional expression is constant */ #endif /* _MSC_VER */ #ifndef LZ4_FORCE_INLINE |