Extension declares a conformance of imported type 'X' to imported protocol 'Y'; this will not behave correctly if the owners of 'CoreFoundation' introduce this conformance in the future
without adding the @retroactive, which does not compile in Xcode 15.
This way, extensions that declares a conformance to a type where both are from another module will compile without warning in Xcode 16, as the conformed type is declared to be explicitly from the imported module, which suppresses the warning.
Fixes the warning in the new Swift version solved here: https://github.com/swiftlang/swift/pull/36068
Which is:
Extension declares a conformance of imported type 'X' to imported protocol 'Y'; this will not behave correctly if the owners of 'CoreFoundation' introduce this conformance in the future
without adding the
@retroactive
, which does not compile in Xcode 15.This way, extensions that declares a conformance to a type where both are from another module will compile without warning in Xcode 16, as the conformed type is declared to be explicitly from the imported module, which suppresses the warning.