Skip to content

Commit d05b334

Browse files
committed
[stdlib] use the Index typealias in Span
- these were missed in a previous code change
1 parent fbaaf53 commit d05b334

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

stdlib/public/core/Span/Span.swift

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -545,7 +545,9 @@ extension Span where Element: ~Copyable {
545545
/// - Complexity: O(1)
546546
@_alwaysEmitIntoClient
547547
@lifetime(self)
548-
public func _extracting(_ bounds: some RangeExpression<Int>) -> Self {
548+
public func _extracting(
549+
_ bounds: some RangeExpression<Index>
550+
) -> Self {
549551
_extracting(bounds.relative(to: indices))
550552
}
551553

@@ -568,7 +570,7 @@ extension Span where Element: ~Copyable {
568570
@_alwaysEmitIntoClient
569571
@lifetime(self)
570572
public func _extracting(
571-
unchecked bounds: some RangeExpression<Int>
573+
unchecked bounds: some RangeExpression<Index>
572574
) -> Self {
573575
unsafe _extracting(unchecked: bounds.relative(to: indices))
574576
}

0 commit comments

Comments
 (0)