File tree Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -612,6 +612,13 @@ public protocol Sequence {
612
612
) -> ( Iterator , UnsafeMutableBufferPointer < Element > . Index )
613
613
}
614
614
615
+ // Provides a default associated type witness for Iterator when the
616
+ // Self type is both a Sequence and an Iterator.
617
+ extension Sequence where Self: IteratorProtocol {
618
+ // @_implements(Sequence, Iterator)
619
+ public typealias _Default_Iterator = Self
620
+ }
621
+
615
622
/// A default makeIterator() function for `IteratorProtocol` instances that
616
623
/// are declared to conform to `Sequence`
617
624
extension Sequence where Self. Iterator == Self {
@@ -622,7 +629,6 @@ extension Sequence where Self.Iterator == Self {
622
629
}
623
630
}
624
631
625
-
626
632
/// A sequence that lazily consumes and drops `n` elements from an underlying
627
633
/// `Base` iterator before possibly returning the first available element.
628
634
///
You can’t perform that action at this time.
0 commit comments