+2019-12-07 Bruno Haible <bruno@clisp.org>
+
+ Fix compilation errors in C++ mode on AIX with xlclang++.
+ Reported by Christian Biesinger <cbiesinger@google.com> in
+ <https://lists.gnu.org/archive/html/bug-gnulib/2019-12/msg00009.html>.
+ * lib/wchar.in.h (mbstate_t): Don't override on AIX.
+
2019-12-07 Bruno Haible <bruno@clisp.org>
Document compilation error in C++ mode on NetBSD 8.0.
/* Override mbstate_t if it is too small.
On IRIX 6.5, sizeof (mbstate_t) == 1, which is not sufficient for
- implementing mbrtowc for encodings like UTF-8. */
-#if !(@HAVE_MBSINIT@ && @HAVE_MBRTOWC@) || @REPLACE_MBSTATE_T@
+ implementing mbrtowc for encodings like UTF-8.
+ On AIX, mbrtowc needs to be overridden, but mbstate_t exists and is large
+ enough and overriding it would cause problems in C++ mode. */
+#if (!(@HAVE_MBSINIT@ && @HAVE_MBRTOWC@) || @REPLACE_MBSTATE_T@) \
+ && !defined _AIX
# if !GNULIB_defined_mbstate_t
typedef int rpl_mbstate_t;
# undef mbstate_t