Extract compiler-specific macro definitions in a new wx/compiler.h.
This solves the problem with wx/defs.h -> wx/platform.h -> wx/setup.h which resolves to msvc/wx/setup.h -> wx/version.h -> wx/cpp.h include path which resulted in __VISUALC__ not being defined in wx/cpp.h. This problem was not new but went unnoticed for a long time and was only discovered when wxCHECK_VISUALC_VERSION() started being used in wx/cpp.h too as now the compiler started warning about wrong #if syntax due to it being undefined. Putting the compiler-specific definitions in a separate file allows this file to be included from wx/cpp.h to ensure that these symbols are always defined in it and also makes things a little better organized. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@74496 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -13,6 +13,8 @@
|
||||
#ifndef _WX_CPP_H_
|
||||
#define _WX_CPP_H_
|
||||
|
||||
#include "wx/compiler.h" /* wxCHECK_XXX_VERSION() macros */
|
||||
|
||||
/* wxCONCAT works like preprocessor ## operator but also works with macros */
|
||||
#define wxCONCAT_HELPER(text, line) text ## line
|
||||
|
||||
@@ -130,7 +132,7 @@
|
||||
#if (defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901L) || \
|
||||
(defined(__cplusplus) && __cplusplus >= 201103L)
|
||||
#define HAVE_VARIADIC_MACROS
|
||||
#elif defined(__GNUC__) && __GNUC__ >= 3
|
||||
#elif wxCHECK_GCC_VERSION(3,0)
|
||||
#define HAVE_VARIADIC_MACROS
|
||||
#elif wxCHECK_VISUALC_VERSION(8)
|
||||
#define HAVE_VARIADIC_MACROS
|
||||
|
Reference in New Issue
Block a user