TheGNUGeneralPublicLicenseisoftenshippedwithGNUsoftware,and isgenerallykeptinafilecalledCOPYINGorLICENSE.Ifyoudonot haveacopyofthelicense,writetotheFreeSoftwareFoundation,
51 Franklin Street, Fifth Floor, Boston, MA 02110-1335 USA. */
/************************************************/ /* check multibyte capability for I18N code */ /************************************************/
/* For platforms which support the ISO C amendement 1 functionality we
support user defined character classes. */ /* Solaris 2.5 has a bug: <wchar.h> must be included before <wctype.h>. */ #ifdefined (HAVE_WCTYPE_H) && defined (HAVE_WCHAR_H) && defined (HAVE_LOCALE_H) # include <wchar.h> # include <wctype.h> # ifdefined (HAVE_ISWCTYPE) && \ defined (HAVE_ISWLOWER) && \ defined (HAVE_ISWUPPER) && \ defined (HAVE_MBSRTOWCS) && \ defined (HAVE_MBRTOWC) && \ defined (HAVE_MBRLEN) && \ defined (HAVE_TOWLOWER) && \ defined (HAVE_TOWUPPER) && \ defined (HAVE_WCHAR_T) && \ defined (HAVE_WCWIDTH) /* system is supposed to support XPG5 */ # define HANDLE_MULTIBYTE 1 # endif #endif
/* If we don't want multibyte chars even on a system that supports them, let
the configuring user turn multibyte support off. */ #ifdefined (NO_MULTIBYTE_SUPPORT) # undef HANDLE_MULTIBYTE #endif
/* Some systems, like BeOS, have multibyte encodings but lack mbstate_t. */ #if HANDLE_MULTIBYTE && !defined (HAVE_MBSTATE_T) # define wcsrtombs(dest, src, len, ps) (wcsrtombs) (dest, src, len, 0) # define mbsrtowcs(dest, src, len, ps) (mbsrtowcs) (dest, src, len, 0) # define wcrtomb(s, wc, ps) (wcrtomb) (s, wc, 0) # define mbrtowc(pwc, s, n, ps) (mbrtowc) (pwc, s, n, 0) # define mbrlen(s, n, ps) (mbrlen) (s, n, 0) # define mbstate_t int #endif
/* Make sure MB_LEN_MAX is at least 16 on systems that claim to be able to
handle multibyte chars (some systems define MB_LEN_MAX as 1) */ #ifdef HANDLE_MULTIBYTE # include <limits.h> # ifdefined(MB_LEN_MAX) && (MB_LEN_MAX < 16) # undef MB_LEN_MAX # endif # if !defined (MB_LEN_MAX) # define MB_LEN_MAX 16 # endif #endif
/************************************************/ /* end of multibyte capability checks for I18N */ /************************************************/
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.