Tiny performance improvement based on RecyclableList<T> benchmarks.
This commit is contained in:
1 parent
391c72ee48
commit
823141400a
1 file changed
+1
-1
@@ -238,7 +238,7 @@ namespace Recyclable.Collections
|
||||
T[] oldMemoryBlock = sourceList._memoryBlock;
|
||||
|
||||
// & WAS SLOWER AS ARRAY
|
||||
Array.Copy(oldMemoryBlock, newMemoryBlock, oldMemoryBlock.Length);
|
||||
new Span<T>(oldMemoryBlock).CopyTo(newMemoryBlock);
|
||||
|
||||
if (oldMemoryBlock.Length >= RecyclableDefaults.MinPooledArrayLength)
|
||||
{
|
||||
|
||||
Reference in new issue
Block a user