Skip to content

Commit

Permalink
Restore call to reserveCapacity
Browse files Browse the repository at this point in the history
  • Loading branch information
numist committed Jun 27, 2019
1 parent 7041d5c commit 3d741f7
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions stdlib/public/core/Diffing.swift
Expand Up @@ -290,6 +290,7 @@ fileprivate func _myers<C,D>(
using trace: [_V]
) -> [CollectionDifference<C.Element>.Change] {
var changes = [CollectionDifference<C.Element>.Change]()
changes.reserveCapacity(trace.count)

var x = a.count
var y = b.count
Expand Down

0 comments on commit 3d741f7

Please sign in to comment.