C examples for wchar.h:mbsrtowcs
function
<cwchar> <wchar.h>
size_t mbsrtowcs (wchar_t* dest, const char** src, size_t max, mbstate_t* ps);
Convert multibyte string to wide-character string
Parameter | Description |
---|---|
dest | Pointer to an array of wchar_t |
src | C multibyte string to be interpreted |
max | Maximum number of wide characters to write to dest. |
ps | Pointer to a mbstate_t object that defines a conversion state. |
The number of wide characters written to dest.
On error, the function sets errno to EILSEQ and returns -1.