-
Notifications
You must be signed in to change notification settings - Fork 10.5k
[DO NOT MERGE] Make Swift 3 / 4 consistent with SE-0054. #12682
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
Conversation
Looks like there were only two issues! RxSwift had this:
which has been fixed in the upstream repository already. Alamofire has this:
where the '!' is effectively unnecessary. The code is still there upstream at https://github.com/Alamofire/Alamofire/blob/master/Source/ResponseSerialization.swift#L371 |
Yup. It looks like we give a working fix-it in both cases as well (replace |
@rudkx One alternative is to emit this as a warning in Swift 3/4 mode, and continue parsing as if it were a ?. |
@slavapestov Yes I mentioned that possibility in another forum. I think that's a reasonable choice for these casts, but probably not for something like |
@swift-ci Please smoke test |
@swift-ci Please test source compatibility |
Updated this commit since cef6c94 is now in, which addresses some bugs in the earlier commit. This is now limited to switching over to using the new tests all the time. I still do not plan on merging this without further investigation, but want to verify where things stand and fix up any remaining code in our tree (e.g. in tests) that I may have missed. |
@swift-ci Please smoke test |
There is still a cast in Foundation that is disallowed by SE-0054. I opened swiftlang/swift-corelibs-foundation#1300 to make it a cast to Optional instead. |
As with Swift 5 mode, make Swift 3 / 4 reject IUOs in places where they are not allowed according to SE-0054.
@swift-ci Please smoke test |
Ran into a couple more casts in Foundation that need to be fixed up: swiftlang/swift-corelibs-foundation#1303 |
@swift-ci Please test source compatibility |
@swift-ci Please smoke test Linux platform |
@swift-ci Please test source compatibility |
Please test with following pull request: @swift-ci Please smoke test |
@shahmishal Any idea what might have happened here? The multi-PR test doesn't seem to have actually started. |
This is was during CI outage yesterday. Please test with following pull request: @swift-ci Please smoke test |
Also, it does not support same repository :( |
Closing in favor of a new PR I will open soon. |
As with Swift 5 mode, make Swift 3 / 4 reject IUOs in places where they are not allowed according to SE-0054.