.BI "size_t mbstowcs(wchar_t *" dest ", const char *" src ", size_t " n );
.fi
.SH DESCRIPTION
-If \fIdest\fP is not a NULL pointer, the \fBmbstowcs\fP() function converts the
+If \fIdest\fP is not a NULL pointer,
+the \fBmbstowcs\fP() function converts the
multibyte string \fIsrc\fP to a wide-character string starting at \fIdest\fP.
-At most \fIn\fP wide characters are written to \fIdest\fP. The conversion starts
-in the initial state. The conversion can stop for three reasons:
+At most \fIn\fP wide characters are written to \fIdest\fP.
+The conversion starts
+in the initial state.
+The conversion can stop for three reasons:
.PP
-1. An invalid multibyte sequence has been encountered. In this case
+1. An invalid multibyte sequence has been encountered.
+In this case
(size_t)(\-1) is returned.
.PP
-2. \fIn\fP non-L'\\0' wide characters have been stored at \fIdest\fP. In this
+2. \fIn\fP non-L'\\0' wide characters have been stored at \fIdest\fP.
+In this
case the number of wide characters written to \fIdest\fP is returned, but the
shift state at this point is lost.
.PP
3. The multibyte string has been completely converted, including the
-terminating '\\0'. In this case the number of wide characters written to
+terminating '\\0'.
+In this case the number of wide characters written to
\fIdest\fP, excluding the terminating L'\\0' character, is returned.
.PP
The programmer must ensure that there is room for at least \fIn\fP wide
.SH "RETURN VALUE"
The \fBmbstowcs\fP() function returns the number of wide characters that make
up the converted part of the wide character string, not including the
-terminating null wide character. If an invalid multibyte sequence was
+terminating null wide character.
+If an invalid multibyte sequence was
encountered, (size_t)(\-1) is returned.
.SH "CONFORMING TO"
C99