summaryrefslogtreecommitdiff
path: root/doc/posix-functions/mbrtowc.texi
blob: c48696d66c416a07ac5cc857b19e89bc4e7ea36a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
@node mbrtowc
@section @code{mbrtowc}
@findex mbrtowc

POSIX specification:@* @url{http://www.opengroup.org/onlinepubs/9699919799/functions/mbrtowc.html}

Gnulib module: mbrtowc

Portability problems fixed by Gnulib:
@itemize
@item
This function is missing on some platforms:
Minix 3.1.8, HP-UX 11.00, IRIX 6.5, Solaris 2.6, mingw, Interix 3.5.
@item
In the C or POSIX locales, this function can return @code{(size_t) -1}
and set @code{errno} to @code{EILSEQ}:
glibc 2.23.
@item
This function returns 0 instead of @code{(size_t) -2} when the input
is empty:
glibc 2.19.
@item
This function returns @code{(size_t) -1} instead of @code{(size_t) -2}
when the input is empty:
AIX 5.1.
@item
This function does not put the state into non-initial state when parsing an
incomplete multibyte character on some platforms:
AIX 5.1, OSF/1 5.1.
@item
This function does not produce correct results in the zh_CN.GB18030 locale on
some platforms:
Solaris 8.
@item
This function fails if the @code{pwc} argument is NULL on some platforms:
Solaris 7.
@item
This function does not ignore the @code{pwc} argument if the string argument is
NULL on some platforms:
OSF/1 5.1.
@item
This function returns the total number of bytes that make up the multibyte
character, not the number of bytes that were needed to complete the multibyte
character, on some platforms:
HP-UX 11.11, Solaris 11 2010-11, mingw, possibly MSVC 14.
@item
This function may not return 0 when parsing the NUL character on some platforms:
Solaris 9.
@end itemize

Portability problems not fixed by Gnulib:
@itemize
@item
On AIX and Windows platforms, @code{wchar_t} is a 16-bit type and therefore cannot
accommodate all Unicode characters.
@end itemize