1
0
Fork 0
mirror of https://github.com/beefytech/Beef.git synced 2025-06-18 08:06:04 +02:00

Improvements to Queue, to bring it more inline with List

This commit is contained in:
Brian Fiete 2020-03-20 09:26:16 -07:00
parent 69cb6d0208
commit 96c53d4a9e
5 changed files with 238 additions and 88 deletions

View file

@ -111,6 +111,12 @@ namespace System
arr[i] = default(T);
}
public static void Clear<T>(T* arr, int length)
{
for (int i = 0; i < length; i++)
arr[i] = default(T);
}
public static void Copy<T, T2>(T[] arrayFrom, int srcOffset, T2[] arrayTo, int dstOffset, int length) where T : var where T2 : var
{
if (((Object)arrayTo == (Object)arrayFrom) && (dstOffset > srcOffset))