Extract common type definitions from wx/defs.h to wx/types.h
Fix the problem with compiling user code including wx/debug.h as the first wxWidgets header under MSW. This ought to work, but didn't, because wx/debug.h included wx/chartype.h without including wx/defs.h (because there is already an inclusion in the other direction), which defines SIZEOF_WCHAR_T required by wx/chartype.h, first. Notice that we repurpose the existing but completely unused (no mentions of it or the symbols defined in it anywhere neither in wxWidgets nor in any of the code search engines) wx/types.h header as it has a fitting name and this avoids having to add a new header and remove the existing one.
This commit is contained in:
@@ -13,8 +13,13 @@
|
||||
#ifndef _WX_WXCHARTYPE_H_
|
||||
#define _WX_WXCHARTYPE_H_
|
||||
|
||||
/* defs.h indirectly includes this file, so don't include it here */
|
||||
#include "wx/platform.h"
|
||||
/*
|
||||
wx/defs.h indirectly includes this file, so we can't include it here,
|
||||
include just its subset which defines SIZEOF_WCHAR_T that is used here
|
||||
(under Unix it's in configure-generated setup.h, so including wx/platform.h
|
||||
would have been enough, but this is not the case under other platforms).
|
||||
*/
|
||||
#include "wx/types.h"
|
||||
|
||||
/* check whether we have wchar_t and which size it is if we do */
|
||||
#if !defined(wxUSE_WCHAR_T)
|
||||
|
Reference in New Issue
Block a user