@@ -12,19 +12,6 @@ func checkMatch<S: Collection, T: Collection>(_ x: S, _ y: T, _ i: S.Index)
12
12
expectEqual ( x [ i] , y [ i] )
13
13
}
14
14
15
- func checkMatchContiguousStorage< S: Collection , T: Collection > ( _ x: S , _ y: T )
16
- where S. Element == T . Element , S. Element: Equatable
17
- {
18
- let xElement = x. withContiguousStorageIfAvailable { $0. first }
19
- let yElement = y. withContiguousStorageIfAvailable { $0. first }
20
- expectEqual ( xElement, yElement)
21
- }
22
-
23
- func checkHasContiguousStorage< S: Collection > ( _ x: S ) {
24
- let hasStorage = x. withContiguousStorageIfAvailable { _ in true } ?? false
25
- expectTrue ( hasStorage)
26
- }
27
-
28
15
SubstringTests . test ( " Equality " ) {
29
16
let s = " abcdefg "
30
17
let s1 = s [ s. index ( s. startIndex, offsetBy: 2 ) ..<
@@ -241,13 +228,6 @@ SubstringTests.test("UTF8View") {
241
228
expectEqual ( " " , String ( t. dropLast ( 100 ) ) !)
242
229
expectEqual ( " " , String ( u. dropFirst ( 100 ) ) !)
243
230
expectEqual ( " " , String ( u. dropLast ( 100 ) ) !)
244
-
245
- checkHasContiguousStorage ( s. utf8)
246
- checkHasContiguousStorage ( t)
247
- checkHasContiguousStorage ( u)
248
- checkMatchContiguousStorage ( Array ( s. utf8) , s. utf8)
249
- checkMatchContiguousStorage ( Array ( t) , t)
250
- checkMatchContiguousStorage ( Array ( u) , u)
251
231
}
252
232
}
253
233
0 commit comments