[Insight-developers] Warnings when building ITK with MSVC

David Doria daviddoria at gmail.com
Sun Sep 16 09:50:25 EDT 2012


When I build ITK with the MSVC 2010 compiler with -Wall added to
CMAKE_CXX_FLAGS, I get hundreds (533) of warnings. I have pasted some
representatives below:

----------------------
C:\Program Files\Microsoft Visual Studio 10.0\VC\INCLUDE\malloc.h:241:
warning: C4548: expression before comma has no effect; expected
expression with side-effect

C:\src\ITK\Modules\ThirdParty\DICOMParser\src\DICOMParser\DICOMParser.cxx:628:
warning: C4242: 'initializing' : conversion from 'int' to 'char',
possible loss of data

c:\src\itk\modules\thirdparty\gdcm\src\gdcm\source\common\gdcmmd5.cxx:70:
warning: C4702: unreachable code

C:\src\ITK\Modules\ThirdParty\KWSys\src\KWSys\SystemTools.cxx:208:
warning: C4242: '=' : conversion from 'int' to 'char', possible loss
of data

c:\src\itk\modules\thirdparty\metaio\src\metaio\metaUtils.h:43:
warning: C4619: #pragma warning : there is no warning number '4284'
----------------------

I don't see these warnings show up on any of the MSVC dashboards - are
there some flags or something that I have to pass to avoid/suppress
these? Or are the dashboards just not built with -Wall?

David


More information about the Insight-developers mailing list