Skip to content

Commit 39579e2

Browse files
committed
more missing eaches in tests
1 parent 89e5648 commit 39579e2

File tree

4 files changed

+5
-5
lines changed

4 files changed

+5
-5
lines changed

test/Constraints/pack_expansion_types.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -257,7 +257,7 @@ func patternInstantiationConcreteInvalid() {
257257
let _: (Array<Int>, Set<String>) = patternInstantiationTupleTest1() // expected-error {{type of expression is ambiguous without more context}}
258258
}
259259

260-
func patternInstantiationGenericValid<T..., U...>(t: repeat each T, u: repeat each U) where (repeat (each T, each U)): Any, T: Hashable {
260+
func patternInstantiationGenericValid<T..., U...>(t: repeat each T, u: repeat each U) where (repeat (each T, each U)): Any, each T: Hashable {
261261
let _: (repeat Array<each T>) = patternInstantiationTupleTest1()
262262
let _: (repeat Array<each T>, Array<String>) = patternInstantiationTupleTest1()
263263
let _: (Array<String>, repeat Array<each T>) = patternInstantiationTupleTest1()
@@ -279,7 +279,7 @@ func patternInstantiationGenericValid<T..., U...>(t: repeat each T, u: repeat ea
279279
let _: (Dictionary<Int, String>, repeat Dictionary<each T, each U>, Dictionary<Double, Character>) -> () = patternInstantiationFunctionTest2()
280280
}
281281

282-
func patternInstantiationGenericInvalid<T...>(t: repeat each T) where T: Hashable {
282+
func patternInstantiationGenericInvalid<T...>(t: repeat each T) where each T: Hashable {
283283
let _: (repeat Set<each T>) = patternInstantiationTupleTest1() // expected-error {{cannot convert value of type '(repeat Array<each T>)' to specified type '(repeat Set<each T>)}}
284284
// expected-error@-1 {{generic parameter 'T' could not be inferred}}
285285

test/Generics/pack-shape-requirements.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ func inferSameShape<T..., U...>(ts t: repeat each T, us u: repeat each U) where
1313

1414
// CHECK-LABEL: desugarSameShape(ts:us:)
1515
// CHECK-NEXT: Generic signature: <T..., U... where T : P, ((T, U)...) : Any, U : P>
16-
func desugarSameShape<T..., U...>(ts t: repeat each T, us u: repeat each U) where T: P, U: P, (repeat (each T.A, each U.A)): Any {
16+
func desugarSameShape<T..., U...>(ts t: repeat each T, us u: repeat each U) where each T: P, each U: P, (repeat (each T.A, each U.A)): Any {
1717
}
1818

1919
// CHECK-LABEL: multipleSameShape1(ts:us:vs:)

test/Generics/tuple-conformances.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ protocol P {
1111
func f()
1212
}
1313

14-
extension Builtin.TheTupleType: P where Elements: P {
14+
extension Builtin.TheTupleType: P where each Elements: P {
1515
typealias A = (repeat each Elements.A)
1616
typealias B = Float
1717
func f() {}

test/type/pack_expansion.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ struct Outer<T...> {
6161
}
6262

6363
struct AlsoGood<U...> {
64-
typealias Value = (repeat (T, E<repeat each U>))
64+
typealias Value = (repeat (each T, E<repeat each U>))
6565
}
6666
}
6767

0 commit comments

Comments
 (0)