Commit 711fccf8 authored by Peter Levine's avatar Peter Levine
Browse files

Don't allow signed/unsigned wchar_t in gcc 9 and later

parent 8ffb7e5c
...@@ -115,8 +115,11 @@ inline Element* GetRawPointer(Element* p) { return p; } ...@@ -115,8 +115,11 @@ inline Element* GetRawPointer(Element* p) { return p; }
// //
// To gcc, // To gcc,
// wchar_t == signed wchar_t != unsigned wchar_t == unsigned int // wchar_t == signed wchar_t != unsigned wchar_t == unsigned int
//
// gcc-9 appears to treat signed/unsigned wchar_t as ill-formed
// regardless of the signage of its underlying type.
#ifdef __GNUC__ #ifdef __GNUC__
#if !defined(__WCHAR_UNSIGNED__) #if !defined(__WCHAR_UNSIGNED__) && (__GNUC__ < 9)
// signed/unsigned wchar_t are valid types. // signed/unsigned wchar_t are valid types.
# define GMOCK_HAS_SIGNED_WCHAR_T_ 1 # define GMOCK_HAS_SIGNED_WCHAR_T_ 1
#endif #endif
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment