mirror of
https://github.com/xcat2/xNBA.git
synced 2024-11-26 03:09:12 +00:00
[build] Default to short wchar_t in stddef.h
sparse does not understand -fshort-wchar. Default to using uint16_t as a wchar_t if not explicitly specified by the compiler, to avoid large numbers of spurious warnings from sparse. Signed-off-by: Michael Brown <mcb30@ipxe.org>
This commit is contained in:
parent
4678864ce6
commit
1aca99f3cf
@ -23,10 +23,10 @@ FILE_LICENCE ( GPL2_ONLY );
|
||||
|
||||
/* __WCHAR_TYPE__ is defined by gcc and will change if -fshort-wchar is used */
|
||||
#ifndef __WCHAR_TYPE__
|
||||
#define __WCHAR_TYPE__ long int
|
||||
#define __WCHAR_TYPE__ uint16_t
|
||||
#endif
|
||||
#ifndef __WINT_TYPE__
|
||||
#define __WINT_TYPE__ long int
|
||||
#define __WINT_TYPE__ int
|
||||
#endif
|
||||
typedef __WCHAR_TYPE__ wchar_t;
|
||||
typedef __WINT_TYPE__ wint_t;
|
||||
|
Loading…
Reference in New Issue
Block a user