aboutsummaryrefslogtreecommitdiffstats
path: root/memory/wmemmove.c
blob: 1d30dafb493d81463f85cd7d078293b85f3b6452 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
#include "memory.h"

wchar_t *wmemmove(wchar_t *restrict destination, wchar_t const *restrict source,
		  size_t count)
{
	if (destination < source)
		wmemcpy(destination, source, count);
	else
		for (size_t i = count; i-- > 0;)
			destination[i] = source[i];
	return destination;
}