📄 memcpy.c
字号:
/*FUNCTION <<memcpy>>---copy memory regionsANSI_SYNOPSIS #include <string.h> void* memcpy(void *<[out]>, const void *<[in]>, size_t <[n]>);TRAD_SYNOPSIS void *memcpy(<[out]>, <[in]>, <[n]> void *<[out]>; void *<[in]>; size_t <[n]>;DESCRIPTION This function copies <[n]> bytes from the memory region pointed to by <[in]> to the memory region pointed to by <[out]>. If the regions overlap, the behavior is undefined.RETURNS <<memcpy>> returns a pointer to the first byte of the <[out]> region.PORTABILITY<<memcpy>> is ANSI C.<<memcpy>> requires no supporting OS subroutines.QUICKREF memcpy ansi pure*/#include <_ansi.h>#include <stddef.h>_PTR_DEFUN (memcpy, (out, in, length), _PTR out _AND _CONST _PTR in _AND size_t length){ char *dst = (char *) out; char *src = (char *) in; _PTR save = out; while (length--) { *dst++ = *src++; } return save;}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -