@@ -19,6 +19,13 @@ public protocol StrongProtoWithWeakLinkedAssoc {
19
19
@_weakLinked associatedtype Assoc : P
20
20
}
21
21
22
+ public struct LibConformsToP : P { }
23
+
24
+ public protocol StrongProtoWithNewAssoc {
25
+ @available ( macOS 10 . 50 , * )
26
+ associatedtype NewerAssoc : P = LibConformsToP
27
+ }
28
+
22
29
@available ( macOS 10 . 50 , * )
23
30
public protocol WeakProtoWithAssoc {
24
31
associatedtype Assoc : P
@@ -40,11 +47,18 @@ struct ConformsToStrongProtoWithAssoc: StrongProtoWithAssoc {
40
47
typealias Assoc = ConformsToP
41
48
}
42
49
50
+
43
51
// CHECK: @"$s7Library30StrongProtoWithWeakLinkedAssocP0G0AC_AA1PTn" = extern_weak global %swift.protocol_requirement, align 4
44
52
struct ConformsToStrongProtoWithWeakLinkedAssoc : StrongProtoWithWeakLinkedAssoc {
45
53
typealias Assoc = ConformsToP
46
54
}
47
55
56
+ // CHECK: @"$s7Library23StrongProtoWithNewAssocP05NewerF0AC_AA1PTn" = extern_weak global %swift.protocol_requirement, align 4
57
+ // CHECK: @"$s10NewerAssoc7Library018StrongProtoWithNewB0PTl" = extern_weak global %swift.protocol_requirement, align 4
58
+ struct ConformsToStrongProtoWithNewAssoc : StrongProtoWithNewAssoc {
59
+ typealias NewAssoc = ConformsToP
60
+ }
61
+
48
62
// CHECK: @"$s7Library18WeakProtoWithAssocP0E0AC_AA1PTn" = extern_weak global %swift.protocol_requirement, align 4
49
63
@available ( macOS 10 . 50 , * )
50
64
struct ConformsToWeakProtoWithAssoc : WeakProtoWithAssoc {
0 commit comments