* doc/posix-headers/wchar.texi: Mention which platforms don’t use Unicode for wchar_t. --- ChangeLog | 4 ++++ doc/posix-headers/wchar.texi | 10 ++++++++++ 2 files changed, 14 insertions(+)
diff --git a/ChangeLog b/ChangeLog index 924dae9a69..0acd1c9162 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,9 @@ 2026-05-05 Paul Eggert <[email protected]> + wchar-h: doc wchar_t limitations + * doc/posix-headers/wchar.texi: Mention which platforms don’t + use Unicode for wchar_t. + localeinfo: wbctowc comment * lib/localeinfo.h: Improve comment. diff --git a/doc/posix-headers/wchar.texi b/doc/posix-headers/wchar.texi index 1fc638b13a..fddebff1ca 100644 --- a/doc/posix-headers/wchar.texi +++ b/doc/posix-headers/wchar.texi @@ -24,6 +24,16 @@ wchar.h Portability problems not fixed by Gnulib: @itemize @item +In multibyte locales, @code{wchar_t} values need not be Unicode code points: +FreeBSD 15, NetBSD 10, AIX, Solaris. +@item +In single-byte locales, @code{wchar_t} values need not be Unicode code points: +FreeBSD 15, NetBSD 10, OpenBSD 7, macOS 26, Solaris, mingw, MSVC. +@item +@code{wchar_t} is only 16 bits, and so can represent only a +UTF-16 subset of Unicode when @code{wchar_t} values are Unicode code points: +32-bit AIX, mingw, MSVC. +@item This header file leads to link errors and endless recursions or endless loops on some platforms: glibc version 2.5 or older, together with gcc version 4.3 or newer and the -- 2.54.0
