@@ -507,7 +507,7 @@ LazyTestSuite.test("MapCollection<${TraversalCollection}>/underestimatedCount")
507
507
OpaqueValue(Int32(input.value))
508
508
}
509
509
expectType(
510
- LazyMap${TraversalCollection} <
510
+ LazyMapCollection <
511
511
Minimal${TraversalCollection}<OpaqueValue<Int>>, OpaqueValue<Int32>
512
512
>.self,
513
513
&lazyMap)
@@ -810,7 +810,7 @@ tests.test("LazyMap${TraversalCollection}/Collection") {
810
810
expectEqual(0, calls)
811
811
812
812
expectType(
813
- LazyMap${TraversalCollection} <
813
+ LazyMapCollection <
814
814
Minimal${TraversalCollection}<OpaqueValue<Int>>,
815
815
OpaqueValue<Double>>.self,
816
816
&mapped)
@@ -926,7 +926,7 @@ tests.test("lazy.mapped/TypeInference") {
926
926
var mapped = MinimalBidirectionalCollection(elements: baseArray)
927
927
.lazy.map { _ in OpaqueValue<Int8>(0) }
928
928
expectType(
929
- LazyMapBidirectionalCollection <
929
+ LazyMapCollection <
930
930
MinimalBidirectionalCollection<OpaqueValue<Int>>,
931
931
OpaqueValue<Int8>
932
932
>.self,
@@ -960,14 +960,14 @@ tests.test("ReversedCollection") {
960
960
}
961
961
962
962
checkBidirectionalCollection(
963
- "raboof".characters ,
964
- "foobar".characters. reversed())
963
+ "raboof",
964
+ "foobar".reversed())
965
965
966
966
// Check that the reverse collection is still eager
967
967
do {
968
968
var calls = 0
969
- _ = "foobar".characters. reversed().map { _ in calls += 1 }
970
- expectEqual("foobar".characters. count, calls)
969
+ _ = "foobar".reversed().map { _ in calls += 1 }
970
+ expectEqual("foobar".count, calls)
971
971
}
972
972
}
973
973
@@ -1002,12 +1002,8 @@ tests.test("ReversedCollection/Lazy") {
1002
1002
}
1003
1003
1004
1004
do {
1005
- typealias Expected = LazyBidirectionalCollection<
1006
- ReversedCollection<String.CharacterView>
1007
- >
1008
-
1009
- let base = "foobar".characters.lazy.map { $0 }
1010
- typealias Base = LazyMapCollection<String.CharacterView, Character>
1005
+ let base = "foobar".lazy.map { $0 }
1006
+ typealias Base = LazyMapCollection<String, Character>
1011
1007
ExpectType<Base>.test(base)
1012
1008
1013
1009
typealias LazyReversedBase = LazyBidirectionalCollection<
@@ -1019,7 +1015,7 @@ tests.test("ReversedCollection/Lazy") {
1019
1015
var calls = 0
1020
1016
let reversedAndMapped = reversed.map { (x) -> Character in calls += 1; return x }
1021
1017
expectEqual(0, calls)
1022
- checkBidirectionalCollection("raboof".characters , reversedAndMapped)
1018
+ checkBidirectionalCollection("raboof", reversedAndMapped)
1023
1019
expectNotEqual(0, calls)
1024
1020
}
1025
1021
}
@@ -1160,7 +1156,7 @@ tests.test("LazyFilterCollection/AssociatedTypes") {
1160
1156
collectionType: Subject.self,
1161
1157
iteratorType: LazyFilterIterator<Base.Iterator>.self,
1162
1158
subSequenceType: LazyFilterCollection<Base.SubSequence>.self,
1163
- indexType: LazyFilterIndex< Base> .self,
1159
+ indexType: Base.Index .self,
1164
1160
indicesType: DefaultIndices<Subject>.self)
1165
1161
}
1166
1162
@@ -1171,7 +1167,7 @@ tests.test("LazyFilterBidirectionalCollection/AssociatedTypes") {
1171
1167
collectionType: Subject.self,
1172
1168
iteratorType: LazyFilterIterator<Base.Iterator>.self,
1173
1169
subSequenceType: LazyFilterCollection<Base.SubSequence>.self,
1174
- indexType: LazyFilterIndex< Base> .self,
1170
+ indexType: Base.Index .self,
1175
1171
indicesType: DefaultBidirectionalIndices<Subject>.self)
1176
1172
}
1177
1173
0 commit comments