#ifndef ARRAY_H
#define ARRAY_H
#include <inttypes.h>
+#include "common.h"
typedef uint32_t uint;
type *array;
uint size;
};
+
+template<typename type>
+void System_arraycopy(Array<type> * src, int32_t srcPos, Array<type> *dst, int32_t dstPos, int32_t len) {
+ if (srcPos + len > src->length() ||
+ dstPos + len > dst->length())
+ ASSERT(0);
+ uint bytesToCopy = len * sizeof(type);
+ memcpy(&dst->internalArray()[dstPos], &src->internalArray()[srcPos], bytesToCopy);
+}
#endif