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

2d array CopyTo

This commit is contained in:
Brian Fiete 2025-05-02 11:40:53 -07:00
parent d48274694e
commit 1e528cba95

View file

@ -570,6 +570,12 @@ namespace System
return &mFirstElement;
}
public void CopyTo(T[,] arrayTo)
{
Debug.Assert(arrayTo.mLength >= mLength);
Internal.MemCpy(&arrayTo.GetRef(0), &GetRef(0), strideof(T) * mLength, alignof(T));
}
public Span<T>.Enumerator GetEnumerator()
{
return .(.(&mFirstElement, mLength));