Skip to content

Commit 6bfe3da

Browse files
authored
Minor typo fix understimatedCap -> underestimatedCap
1 parent 1374147 commit 6bfe3da

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

stdlib/public/core/String.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -590,10 +590,10 @@ extension Sequence where Element: StringProtocol {
590590
internal func _joined(separator: String) -> String {
591591
// A likely-under-estimate, but lets us skip some of the growth curve
592592
// for large Sequences.
593-
let understimatedCap =
593+
let underestimatedCap =
594594
(1 &+ separator._guts.count) &* self.underestimatedCount
595595
var result = ""
596-
result.reserveCapacity(understimatedCap)
596+
result.reserveCapacity(underestimatedCap)
597597
if separator.isEmpty {
598598
for x in self {
599599
result.append(x._ephemeralString)

0 commit comments

Comments
 (0)