From: Szabolcs Nagy Date: Sun, 8 Jul 2018 13:19:03 +0000 (+0200) Subject: uchar.h: define char16_t and char32_t for old c++ X-Git-Tag: v1.1.20~41 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=cbf16c4abf63e47c2e8b34faac8a2a74a64973b5;p=oweals%2Fmusl.git uchar.h: define char16_t and char32_t for old c++ including uchar.h in c++ code is only well defined in c++11 onwards where char16_t and char32_t type definitions must be hidden since they are keywords. however some c++ code compiled for older c++ standard include uchar.h too and they need the typedefs, this fix makes such code work. --- diff --git a/include/uchar.h b/include/uchar.h index 8dabf1ed..7e5c4d40 100644 --- a/include/uchar.h +++ b/include/uchar.h @@ -3,7 +3,9 @@ #ifdef __cplusplus extern "C" { -#else +#endif + +#if __cplusplus < 201103L typedef unsigned short char16_t; typedef unsigned char32_t; #endif