New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[SR-13400] Generic placeholders have broken for Any's metatypes. #55841
Comments
@swift-ci create |
They're not the same. `Any.Type` is the type of all types that conform to `Any`, whereas `Parameter.Type` is `Any.Protocol`, which is just the type `Any` itself. The syntax is a bit unfortunate. |
Jessy (JIRA User) do you have a specific example where you were trying to use this and it didn't work? Maybe we can improve the diagnostic for that case to explain the difference. |
Comment by Jessy Catterwaul (JIRA) Sorry, maybe I got it wrong. Here's the simplest example of the breaking change: ```swift protocol Protocol { } // These succeed in Xcode 11 but fail in Xcode 12. What is the real issue? Do you need a new bug report? Feel free to edit this one's title. |
Jessy (JIRA User) I've reopened the bug report. I tried reproducing the issue with v2 of the playground on Xcode 11 beta 7 and Xcode 12 beta 4 and got a success for both of them. Could you give more precise Xcode versions? Alternatively, if you could share the output of `xcrun swiftc --version` for each Xcode, that would help. |
Comment by Jessy Catterwaul (JIRA) Xcode 12 beta 5 and 6 is where I noticed the problem. Here's what I've got in beta 6: Apple Swift version 5.3 (swiftlang-1200.0.28.1 clang-1200.0.30.1) |
Attachment: Download
Additional Detail from JIRA
md5: 549e44f9d5ee54d214bfb263868ecd0f
Issue Description:
Any.Type.self and Parameter.Type.self should be the same, but they are not. It's causing me some problems.
The text was updated successfully, but these errors were encountered: