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
Sema: Fix @retroactive does not apply diags for same package conformance.
SE-0364 was amended to allow same-package conformances to be considered
non-retroactive. The logic for that ammendment was implemented in Swift 6.0,
but the diagnostics were not updated.
Resolves rdar://133423931.
extensionExternalLibraryClass:ExternalLibraryProtocol{} // expected-warning {{extension declares a conformance of imported type 'ExternalLibraryClass' to imported protocol 'ExternalLibraryProtocol'; this will not behave correctly if the owners of 'ExternalLibrary' introduce this conformance in the future}}
53
+
// expected-note @-1 {{add '@retroactive' to silence this warning}} {{33-56=@retroactive ExternalLibraryProtocol}}
54
+
55
+
extensionExternalLibraryClass:LibraryProtocol{}
56
+
extensionLibraryClass:ExternalLibraryProtocol{}
57
+
58
+
extensionExternalLibraryClass:@retroactiveOtherLibraryProtocol{} // expected-warning {{'retroactive' attribute does not apply; 'OtherLibraryProtocol' is declared in the same package; this is an error in the Swift 6 language mode}}
59
+
extensionOtherLibraryClass:@retroactiveExternalLibraryProtocol{} // expected-warning {{'retroactive' attribute does not apply; 'OtherLibraryClass' is declared in the same package; this is an error in the Swift 6 language mode}}
0 commit comments