Skip to content

Commit 7c98b49

Browse files
committed
Merge pull request #2841 from ahoppen/SR-1236-tests-update
2 parents da40b5e + 2108a23 commit 7c98b49

File tree

9 files changed

+124
-123
lines changed

9 files changed

+124
-123
lines changed

stdlib/private/StdlibCollectionUnittest/MinimalCollections.swift.gyb

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -157,23 +157,23 @@ internal enum _CollectionOperation : Equatable {
157157
var newElementsIds = elementsLastMutatedStateIds
158158
var newEndIndexId = endIndexLastMutatedStateId
159159
switch self {
160-
case reserveCapacity:
160+
case .reserveCapacity:
161161
let invalidIndices = newElementsIds.indices
162162
newElementsIds.replaceSubrange(
163163
Range(invalidIndices),
164164
with: repeatElement(nextStateId, count: invalidIndices.count))
165165
newEndIndexId = nextStateId
166166

167-
case append:
167+
case .append:
168168
newElementsIds.append(nextStateId)
169169
newEndIndexId = nextStateId
170170

171-
case appendContentsOf(let count):
171+
case .appendContentsOf(let count):
172172
newElementsIds.append(contentsOf:
173173
repeatElement(nextStateId, count: count))
174174
newEndIndexId = nextStateId
175175

176-
case replaceRange(let subRange, let replacementCount):
176+
case .replaceRange(let subRange, let replacementCount):
177177
newElementsIds.replaceSubrange(
178178
subRange,
179179
with: repeatElement(nextStateId, count: replacementCount))
@@ -184,7 +184,7 @@ internal enum _CollectionOperation : Equatable {
184184
with: repeatElement(nextStateId, count: invalidIndices.count))
185185
newEndIndexId = nextStateId
186186

187-
case insert(let atIndex):
187+
case .insert(let atIndex):
188188
newElementsIds.insert(nextStateId, at: atIndex)
189189

190190
let invalidIndices = atIndex..<newElementsIds.endIndex
@@ -193,7 +193,7 @@ internal enum _CollectionOperation : Equatable {
193193
with: repeatElement(nextStateId, count: invalidIndices.count))
194194
newEndIndexId = nextStateId
195195

196-
case insertContentsOf(let atIndex, let count):
196+
case .insertContentsOf(let atIndex, let count):
197197
newElementsIds.insert(
198198
contentsOf: repeatElement(nextStateId, count: count),
199199
at: atIndex)
@@ -204,7 +204,7 @@ internal enum _CollectionOperation : Equatable {
204204
with: repeatElement(nextStateId, count: invalidIndices.count))
205205
newEndIndexId = nextStateId
206206

207-
case removeAtIndex(let index):
207+
case .removeAtIndex(let index):
208208
newElementsIds.remove(at: index)
209209

210210
let invalidIndices = index..<newElementsIds.endIndex
@@ -213,11 +213,11 @@ internal enum _CollectionOperation : Equatable {
213213
with: repeatElement(nextStateId, count: invalidIndices.count))
214214
newEndIndexId = nextStateId
215215

216-
case removeLast:
216+
case .removeLast:
217217
newElementsIds.removeLast()
218218
newEndIndexId = nextStateId
219219

220-
case removeRange(let subRange):
220+
case .removeRange(let subRange):
221221
newElementsIds.removeSubrange(subRange)
222222

223223
let invalidIndices = subRange.lowerBound..<newElementsIds.endIndex
@@ -226,7 +226,7 @@ internal enum _CollectionOperation : Equatable {
226226
with: repeatElement(nextStateId, count: invalidIndices.count))
227227
newEndIndexId = nextStateId
228228

229-
case removeAll(let keepCapacity):
229+
case .removeAll(let keepCapacity):
230230
newElementsIds.removeAll(keepingCapacity: keepCapacity)
231231
newEndIndexId = nextStateId
232232
}

0 commit comments

Comments
 (0)