mbtowc - C stdlib.h

C examples for stdlib.h:mbtowc

Type

function

From


<cstdlib>
<stdlib.h>

Description

Convert multibyte sequence to wide character

Prototype

int mbtowc (wchar_t* pwc, const char* pmb, size_t max);

Parameters

Parameter Description
pwc Pointer to type wchar_t string.
pmb Pointer to a multibyte character.
max Maximum number of bytes of pmb to consider for the multibyte character.

Return Value

On success, the size of the multibyte character pointed by pmb is returned.

On error, -1 is returned.


Related Tutorials