Remove VS 2019 warnings

This commit is contained in:
Gaute Lindkvist 2019-11-27 14:03:35 +01:00
parent 1267ba64d4
commit e31f2d2b50
2 changed files with 5 additions and 4 deletions

View File

@ -379,11 +379,12 @@ add_executable( ResInsight ${EXE_FILES})
if (MSVC)
# The following warnings are supposed to be used in ResInsight, but temporarily disabled to avoid too much noise
# warning C4245: 'return': conversion from 'int' to 'size_t', signed/unsigned mismatch
# warning C4005: Macro redefinition for math constants (M_PI, M_SQRT2 etc)
# If possible, the following command is supposed to be the final target
# set_target_properties(ResInsight PROPERTIES COMPILE_FLAGS "/W4 /wd4190 /wd4100 /wd4127")
set_target_properties(ResInsight PROPERTIES COMPILE_FLAGS "/W4 /wd4190 /wd4100 /wd4127 /wd4245")
set_target_properties(ResInsight PROPERTIES COMPILE_FLAGS "/W4 /wd4190 /wd4100 /wd4127 /wd4245 /wd4005")
if (CMAKE_CXX_COMPILER_VERSION LESS_EQUAL 19.14)
# The following warning is generated over 800 times from a qwt header only using VS2015
# Disabling temporarily

View File

@ -157,9 +157,9 @@ TEST( RiaProjectFileVersionTools, OrderKnownVersionStrings )
QStringList sortedVersionList = versionStrings;
{
qSort( sortedVersionList.begin(),
sortedVersionList.end(),
RiaProjectFileVersionTools::isCandidateVersionNewerThanOther );
std::sort( sortedVersionList.begin(),
sortedVersionList.end(),
RiaProjectFileVersionTools::isCandidateVersionNewerThanOther );
}
/*