Copy byte buffer


memcpy( dest[], source[], index, length )

Copy the source string to dest, starting at the index byte in dest, and counting length bytes.


dest destination buffer
source string to be copied
index offset in source
length number of bytes to copy

Return value

Returns number of bytes copied.

Example usage

    new s1{20};
    new s2{20};
    strcopy(s1, "ABCdef");
    memcpy(s2, s1, 3, 3);    
    // s2 now contains "def" - NOTE that no terminating NULL character is copied
  • ezeio2/scriptref/memcpy.txt
  • Last modified: 2019-11-18 22:37
  • by andreh