You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: test/decl/protocol/req/associated_type_tuple.swift
+4-4Lines changed: 4 additions & 4 deletions
Original file line number
Diff line number
Diff line change
@@ -9,16 +9,16 @@ protocol P1 {
9
9
extensionTuple:P1whererepeateachT:P1{} // expected-error {{type '(repeat each T)' does not conform to protocol 'P1'}}
10
10
11
11
protocolP2{
12
-
associatedtypeA=Int // expected-note {{default type 'Int' for associated type 'A' (from protocol 'P2') is unsuitable for tuple conformance; the associated type requirement must be fulfilled by a type alias with underlying type '(repeat (each T).A)'}}
12
+
associatedtypeB=Int // expected-note {{default type 'Int' for associated type 'B' (from protocol 'P2') is unsuitable for tuple conformance; the associated type requirement must be fulfilled by a type alias with underlying type '(repeat (each T).B)'}}
13
13
}
14
14
15
15
extensionTuple:P2whererepeateachT:P2{} // expected-error {{type '(repeat each T)' does not conform to protocol 'P2'}}
16
16
17
17
protocolP3{
18
-
associatedtypeA // expected-note {{unable to infer associated type 'A' for protocol 'P3'}}
19
-
func f()->A
18
+
associatedtypeC // expected-note {{unable to infer associated type 'C' for protocol 'P3'}}
19
+
func f()->C
20
20
}
21
21
22
22
extensionTuple:P3whererepeateachT:P3{ // expected-error {{type '(repeat each T)' does not conform to protocol 'P3'}}
23
-
func f()->Int{} // expected-note {{cannot infer 'A' = 'Int' in tuple conformance because the associated type requirement must be fulfilled by a type alias with underlying type '(repeat (each T).A)'}}
23
+
func f()->Int{} // expected-note {{cannot infer 'C' = 'Int' in tuple conformance because the associated type requirement must be fulfilled by a type alias with underlying type '(repeat (each T).C)'}}
0 commit comments