|
2 | 2 | //
|
3 | 3 | // This source file is part of the Swift.org open source project
|
4 | 4 | //
|
5 |
| -// Copyright (c) 2014 - 2017 Apple Inc. and the Swift project authors |
| 5 | +// Copyright (c) 2014 - 2020 Apple Inc. and the Swift project authors |
6 | 6 | // Licensed under Apache License v2.0 with Runtime Library Exception
|
7 | 7 | //
|
8 | 8 | // See https://swift.org/LICENSE.txt for license information
|
@@ -941,7 +941,7 @@ public func checkOneLevelOfRandomAccessCollection<
|
941 | 941 | instances,
|
942 | 942 | distances: distances,
|
943 | 943 | of: collection,
|
944 |
| - distanceOracle: { (x:Int, y:Int) in numericCast(y - x) }, |
| 944 | + distanceOracle: { (x:Int, y:Int) in y - x }, |
945 | 945 | advanceOracle: { x, y in nextN(distances[y], instances[x]) },
|
946 | 946 | startIndex: collection.startIndex,
|
947 | 947 | endIndex: next5(partWay1), message(),
|
@@ -1709,7 +1709,7 @@ public func checkOneLevelOfRandomAccessCollection<
|
1709 | 1709 | instances,
|
1710 | 1710 | distances: distances,
|
1711 | 1711 | of: collection,
|
1712 |
| - distanceOracle: { (x:Int, y:Int) in numericCast(y - x) }, |
| 1712 | + distanceOracle: { (x:Int, y:Int) in y - x }, |
1713 | 1713 | advanceOracle: { x, y in nextN(distances[y], instances[x]) },
|
1714 | 1714 | startIndex: collection.startIndex,
|
1715 | 1715 | endIndex: next5(partWay1), message(),
|
@@ -1888,7 +1888,7 @@ public func checkRangeReplaceable<C, N>(
|
1888 | 1888 | let growth = newCount - oldCount
|
1889 | 1889 |
|
1890 | 1890 | let expectedCount = source.count + growth
|
1891 |
| - let actualCount = numericCast(a.count) as Int |
| 1891 | + let actualCount = a.count |
1892 | 1892 | if actualCount != expectedCount {
|
1893 | 1893 | reportFailure(
|
1894 | 1894 | &a, "\(actualCount) != expected count \(expectedCount)")
|
|
0 commit comments