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-6922] [SE-0143] [release mode] type ... does not conform to protocol ... #49471
Comments
Probably related to WMO vs. single-file compilation. @swift-ci create |
Comment by tanner0101 (JIRA) I tried creating a smaller repro case for this to make things easier for you guys but couldn't get it to happen. Even with a similar setup in an SPM project (two modules, release mode). I've tagged the core repo at least, so you should be able to easily recreate this:
|
Comment by tanner0101 (JIRA) |
Comment by tanner0101 (JIRA) Any updates on this? I'm worried this is going to make it into Swift 4.1.0 release. |
Any news on this? |
I think it's unlikely we'll have time to address this in Swift 4.1. It's not great to ship a feature with known bugs, especially when we don't understand the root cause yet, but at least it's a new feature, which means it's not breaking existing code. It's possible that a non-WMO build would succeed, but I don't know if there's any way to turn that off from SwiftPM. |
Comment by tanner0101 (JIRA) This change fixes the problem.
|
Comment by tanner0101 (JIRA) Where you have:
It seems the problem is that the `extension Array: X` is not properly implying conformance to `Y` |
That was almost certainly the problem. The compiler didn't accept implicit conditional conformance in a broken way, leading to inconsistencies and brokenness like this. As of apple/swift-evolution#809 and #15268 (available in the 2018-04-04 snapshot), the compiler prompts for the explicit conformance (and offers help to write it via a few different fixits that are slightly syntactically wrong in that snapshot but should be fixed in the next one), and so this doesn't crash any more. Thanks for filing! |
tannernelson (JIRA User), Could you verify if the problem is fixed and if so move the JIRA to "Closed"? |
tannernelson (JIRA User), Could you verify if the problem is fixed and/or move the JIRA to "Closed"? |
Closing the bug. Feel free to reopen if the issue is not resolved. |
Environment
macOS 10.13.2
Xcode 9.2
Swift 2018-02-01
Additional Detail from JIRA
md5: 5583323ce1401d66f0c4828686300777
is duplicated by:
relates to:
Issue Description:
Code using conditional conformance that compiles in debug mode is not compiling in release mode.
To recreate, compile this code in release mode (in Xcode, CLI not tested)
vapor/core@28ee900
The text was updated successfully, but these errors were encountered: