Tiny cleanup
This commit is contained in:
1 parent
ea1d7d91ba
commit
06ef3d4fa4
1 file changed
+1
-2
@@ -83,8 +83,7 @@ namespace Recyclable.Collections
|
|||||||
var sourceBlockCount = source?.Length ?? 0;
|
var sourceBlockCount = source?.Length ?? 0;
|
||||||
int requiredBlockCount = (int)(newCapacity / blockSize) + (newCapacity % blockSize > 0 ? 1 : 0);
|
int requiredBlockCount = (int)(newCapacity / blockSize) + (newCapacity % blockSize > 0 ? 1 : 0);
|
||||||
|
|
||||||
Span<T[]> sourceSpan;
|
Span<T[]> sourceSpan, newArraySpan;
|
||||||
Span<T[]> newArraySpan;
|
|
||||||
T[][] newMemoryBlocks = requiredBlockCount >= RecyclableDefaults.MinPooledArrayLength
|
T[][] newMemoryBlocks = requiredBlockCount >= RecyclableDefaults.MinPooledArrayLength
|
||||||
? arrayPool.Rent(requiredBlockCount)
|
? arrayPool.Rent(requiredBlockCount)
|
||||||
: new T[requiredBlockCount][];
|
: new T[requiredBlockCount][];
|
||||||
|
|||||||
Reference in new issue
Block a user