From 38db7e5e019a04813db363524e4ede0296344e77 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Herm=C3=A8s=20B=C3=A9lusca-Ma=C3=AFto?= Date: Sat, 14 Sep 2013 13:18:51 +0000 Subject: [PATCH] [CMAKE:MSVC] Add warning C4090 (different 'modifier' qualifiers -- for C programs only; for C++ programs, the compiler error C2440 is issued --) as an error (usually, when I hit this warning, it means that I'm doing an error in my code...). This warning can be caused when a pointer to a const or volatile item is assigned to a pointer not declared as pointing to const or volatile. This warning is already treated as an error by GCC... svn path=/trunk/; revision=60100 --- reactos/cmake/msvc.cmake | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/reactos/cmake/msvc.cmake b/reactos/cmake/msvc.cmake index 9e8000e71e7..53fe6008d00 100644 --- a/reactos/cmake/msvc.cmake +++ b/reactos/cmake/msvc.cmake @@ -31,9 +31,13 @@ endif () # C++ exception specification ignored... yeah we don't care add_compile_flags("/wd4290") -# different level of indirection, void function returning a value and -# uninitialized variable usage should be errors. -add_compile_flags("/we4047 /we4098 /we4700") +# The following warnings are treated as errors: +# - C4047: different level of indirection +# - C4090: different 'modifier' qualifiers (for C programs only; +# for C++ programs, the compiler error C2440 is issued) +# - C4098: void function returning a value +# - C4700: uninitialized variable usage +add_compile_flags("/we4047 /we4090 /we4098 /we4700") # Debugging #if(${CMAKE_BUILD_TYPE} STREQUAL "Debug") -- 2.17.1