Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
May 30, 2011, 12:22:19 AM (13 years ago)
Author:
rgrieder
Message:

Fixed MSVC warnings in Convert.h in a different fashion that doesn't require CMake code.

Location:
code/branches/unity_build/src/libraries/util
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • code/branches/unity_build/src/libraries/util/CMakeLists.txt

    r8558 r8676  
    4242)
    4343
    44 IF(MSVC)
    45   # Simply using #pragma warning(disable:4244) doesn't really disable it
    46   # if the warning occurs in a template in another file
    47   # Hence promote it manually to a higher warning level (4)
    48   SET_SOURCE_FILES_PROPERTIES(MultiType.cc PROPERTIES COMPILE_FLAGS "-w44244")
    49 ENDIF()
    50 
    5144ORXONOX_ADD_LIBRARY(util
    5245  FIND_HEADER_FILES
  • code/branches/unity_build/src/libraries/util/Convert.h

    r8351 r8676  
    133133#include "ImplicitConversion.h"
    134134
     135// disable warnings about possible loss of data
     136#ifdef ORXONOX_COMPILER_MSVC
     137#  pragma warning(push)
     138#  pragma warning(disable:4244)
     139#endif
     140
    135141namespace orxonox
    136142{
     
    471477}
    472478
     479// Reinstate warnings
     480#ifdef ORXONOX_COMPILER_MSVC
     481#  pragma warning(pop)
     482#endif
     483
    473484#endif /* _Convert_H__ */
Note: See TracChangeset for help on using the changeset viewer.