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
returntrue // expected-error {{cannot convert return expression of type 'Bool' to return type 'Int'}}
137
164
}
138
165
}
139
166
167
+
extensionString:InternalProto{} // expected-error {{type 'String' does not conform to protocol 'InternalProto'}}
168
+
169
+
extensionInt:PublicRethrowsProto{
170
+
publicfunc req()throws->Int{
171
+
returntrue // expected-error {{cannot convert return expression of type 'Bool' to return type 'Int'}}
172
+
}
173
+
}
174
+
140
175
structInternalStructConformingToPublicProto:PublicProto{ // expected-error {{type 'InternalStructConformingToPublicProto' does not conform to protocol 'PublicProto'}}
structInternalStructConformingToInternalProto:InternalProto{ // expected-error {{type 'InternalStructConformingToInternalProto' does not conform to protocol 'InternalProto'}}
147
182
}
148
183
184
+
structInternalStructForConstraint{}
185
+
186
+
extensionPublicGenericStructwhere T ==InternalStructForConstraint{}
187
+
188
+
extensionPublicGenericStruct:EmptyPublicProtowhere T ==InternalStructForConstraint{}
// CHECK: @rethrows public protocol PublicRethrowsProto {
36
+
// CHECK: func req() throws -> Swift.Int
37
+
// CHECK: }
38
+
// CHECK: #endif
32
39
// CHECK: public struct PublicStruct {
33
40
// CHECK: public init(x: Swift.Int)
34
41
// CHECK: public func publicMethod() -> Swift.Int
35
42
// CHECK: public static func publicStaticMethod()
36
43
// CHECK: }
44
+
// CHECK: public struct PublicGenericStruct<T> {
45
+
// CHECK: public func publicMethod() -> T
46
+
// CHECK: }
37
47
// CHECK: public class PublicClass {
38
48
// CHECK: public init(x: Swift.Int)
39
49
// CHECK: public func publicMethod() -> Swift.Int
40
50
// CHECK: public class func publicClassMethod()
41
51
// CHECK: deinit
42
52
// CHECK: }
43
-
// CHECK: public struct PublicStructConformingToPublicProto : PublicProto {
53
+
// CHECK: @_inheritsConvenienceInitializers public class PublicDerivedClass : lazy_typecheck.PublicClass {
54
+
// CHECK: override public init(x: Swift.Int)
55
+
// CHECK: deinit
56
+
// CHECK: }
57
+
// CHECK: public struct PublicStructConformingToPublicProto : lazy_typecheck.PublicProto {
58
+
// CHECK: public init()
59
+
// CHECK: public func req() -> Swift.Int
60
+
// CHECK: }
61
+
// CHECK: public struct PublicStructIndirectlyConformingToPublicProto {
44
62
// CHECK: public init()
45
63
// CHECK: public func req() -> Swift.Int
46
64
// CHECK: }
47
-
// CHECK: public class PublicClassConformingToPublicProto : PublicProto {
65
+
// CHECK: public class PublicClassConformingToPublicProto : lazy_typecheck.PublicProto {
48
66
// CHECK: public init()
49
67
// CHECK: public func req() -> Swift.Int
50
68
// CHECK: deinit
51
69
// CHECK: }
52
-
// CHECK: extension Swift.String : PublicProto {
70
+
// CHECK: @_inheritsConvenienceInitializers public class PublicClassInheritingConformanceToPublicProto : lazy_typecheck.PublicClassConformingToPublicProto {
0 commit comments