Next: , Previous: wmemmove, Up: Wchar strings


6.5 wmemset—set wide characters in memory

Synopsis

     #include <wchar.h>
     wchar_t *wmemset(wchar_t *s, wchar_t c, size_t n);
     

Description
The wmemset function copies the value of c into each of the first n wide characters of the object pointed to by s. This function is not affected by locale and all wchar_t values are treated identically. The null wide character and wchar_t values not corresponding to valid characters are not treated specially.

If n is zero, s must be a valid pointer and the function copies zero wide characters.


Returns
The wmemset function returns the value of s.


Portability
wmemset is ISO/IEC 9899/AMD1:1995 (ISO C).

No supporting OS subroutines are required.