@@ -100,7 +100,7 @@ extension ${Self} : ArrayType {
100
100
buffer = Buffer ( )
101
101
reserve ( count)
102
102
var p = buffer. elementStorage
103
- for _ in 0 ... count {
103
+ for _ in 0 . . count {
104
104
p++ . initialize ( value)
105
105
}
106
106
buffer. count = count
@@ -156,7 +156,7 @@ extension ${Self} : ArrayType {
156
156
mutating func reserve( newCapacity: Int) {
157
157
if !buffer. requestUniqueMutableBuffer ( newCapacity) {
158
158
var newBuffer = NativeArrayBuffer < T > ( count: count, minimumCapacity: newCapacity)
159
- buffer. _uninitializedCopy ( 0 ... count, target: newBuffer. elementStorage)
159
+ buffer. _uninitializedCopy ( 0 . . count, target: newBuffer. elementStorage)
160
160
buffer = Buffer ( newBuffer)
161
161
}
162
162
assert ( capacity >= newCapacity)
@@ -173,21 +173,21 @@ extension ${Self} : ArrayType {
173
173
assert ( count > 0 , " can't pop from an empty ${Self} " )
174
174
let c = count
175
175
let result = self [ c - 1 ]
176
- replace ( & self , ( c - 1 ) ... c, EmptyCollection ( ) )
176
+ replace ( & self , ( c - 1 ) . . c, EmptyCollection ( ) )
177
177
return result
178
178
}
179
179
180
180
/// Insert an element at the given index in O(N). Requires: atIndex
181
181
/// <= count
182
182
mutating func insert( atIndex: Int, newElement: T) {
183
- replace ( & self , atIndex... atIndex, CollectionOfOne ( newElement) )
183
+ replace ( & self , atIndex . . atIndex, CollectionOfOne ( newElement) )
184
184
}
185
185
186
186
/// Remove the element at the given index. Worst case complexity:
187
187
/// O(N). Requires: index < count
188
188
mutating func removeAt( index: Int) - > T {
189
189
let result = self [ index]
190
- replace ( & self , index... ( index + 1 ) , EmptyCollection ( ) )
190
+ replace ( & self , index . . ( index + 1 ) , EmptyCollection ( ) )
191
191
return result
192
192
}
193
193
@@ -221,7 +221,7 @@ extension ${Self} : ArrayType {
221
221
let count = self . count
222
222
result. reserve ( count)
223
223
var p = result. buffer. elementStorage
224
- for i in 0 ... count {
224
+ for i in 0 . . count {
225
225
p++ . initialize ( transform ( self [ i] ) )
226
226
}
227
227
result. buffer. count = count
@@ -356,7 +356,7 @@ func replace<
356
356
elements [ j] = newValues [ i++ ]
357
357
}
358
358
// Initialize the hole left by sliding the tail forward
359
- for j in oldTailIndex... newTailIndex {
359
+ for j in oldTailIndex . . newTailIndex {
360
360
( elements + j) . initialize ( newValues [ i++ ] )
361
361
}
362
362
}
@@ -535,9 +535,9 @@ func _arrayOutOfPlaceUpdate<
535
535
backing. count = 0
536
536
}
537
537
else {
538
- let newStart = source. _uninitializedCopy ( 0 ... headCount, target: destStart)
538
+ let newStart = source. _uninitializedCopy ( 0 . . headCount, target: destStart)
539
539
initializeNewElements. call ( newStart)
540
- source. _uninitializedCopy ( headCount + oldCount... sourceCount,
540
+ source. _uninitializedCopy ( headCount + oldCount. . sourceCount,
541
541
target: newEnd)
542
542
}
543
543
source = Buffer ( dest!)
0 commit comments