diff --git a/Recyclable.Collections/RecyclableList.cs b/Recyclable.Collections/RecyclableList.cs index c50fe3f..180bd41 100644 --- a/Recyclable.Collections/RecyclableList.cs +++ b/Recyclable.Collections/RecyclableList.cs @@ -433,9 +433,8 @@ namespace Recyclable.Collections if (oldCount > 0) { - var sourceSpan = new Span(_memoryBlock, index, oldCount); - var targetSpan = new Span(_memoryBlock, index + 1, oldCount); - sourceSpan.CopyTo(targetSpan); + new Span(_memoryBlock, index, oldCount) + .CopyTo(new Span(_memoryBlock, index + 1, oldCount)); } _memoryBlock[index] = item;