[SR-3027] add Array.init(minimumCapacity: Int) #45617
Labels
duplicate
Resolution: Duplicates another issue
feature
A feature request or implementation
standard library
Area: Standard library umbrella
swift evolution implemented
Flag → feature: A feature that was approved through the Swift evolution process and implemented
Additional Detail from JIRA
md5: d556fbb29aa1b408f5119b1b265e25ca
duplicates:
Issue Description:
Array and RangeReplaceableCollection has declared function reserveCapacity()
and there is no initializer that allows get Array with reserverCapacity, like
therefore to get empty array with reserved capacity I have to do
that looks like unecessary. What if we have convenient initializer with minimum capacity parameter so empty array capacity don't have to be reallocated after allocation.
The text was updated successfully, but these errors were encountered: