Conditionally disable deprecated warnings

Warning C4786 has been removed from MSVC2013.
Warning C4231 has been removed since MSVC2003 .net.
Added #ifdef statements to only suppress these warnings when the
compiler versions supports them.

Change-Id: I47d6116bc02cdeef6b2172be0b09d105af9d0059
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
bb10
Kurt Pattyn 2014-01-12 19:10:30 +01:00 committed by The Qt Project
parent f58dff46f5
commit 5b570c287f
1 changed files with 6 additions and 2 deletions

View File

@ -826,9 +826,13 @@ Q_CORE_EXPORT void qFreeAligned(void *ptr);
# pragma warning(disable: 4800) /* 'type' : forcing value to bool 'true' or 'false' (performance warning) */
# pragma warning(disable: 4097) /* typedef-name 'identifier1' used as synonym for class-name 'identifier2' */
# pragma warning(disable: 4706) /* assignment within conditional expression */
# pragma warning(disable: 4786) /* 'identifier' : identifier was truncated to 'number' characters in the debug information */
# if _MSC_VER <= 1310 // MSVC 2003
# pragma warning(disable: 4786) /* 'identifier' : identifier was truncated to 'number' characters in the debug information */
# endif
# pragma warning(disable: 4355) /* 'this' : used in base member initializer list */
# pragma warning(disable: 4231) /* nonstandard extension used : 'identifier' before template explicit instantiation */
# if _MSC_VER < 1800 // MSVC 2013
# pragma warning(disable: 4231) /* nonstandard extension used : 'identifier' before template explicit instantiation */
# endif
# pragma warning(disable: 4710) /* function not inlined */
# pragma warning(disable: 4530) /* C++ exception handler used, but unwind semantics are not enabled. Specify /EHsc */
# elif defined(Q_CC_BOR)