[stdlib] Remove more unneeded numericCasts

This commit is contained in:
Ben Rimmington
2020-05-10 12:31:55 +01:00
parent 37657d0e06
commit f2c952cb69
12 changed files with 129 additions and 129 deletions

View File

@@ -25,11 +25,11 @@ import ucrt
extension Collection {
internal func index(_nth n: Int) -> Index {
precondition(n >= 0)
return index(startIndex, offsetBy: numericCast(n))
return index(startIndex, offsetBy: n)
}
internal func index(_nthLast n: Int) -> Index {
precondition(n >= 0)
return index(endIndex, offsetBy: -numericCast(n))
return index(endIndex, offsetBy: -n)
}
}