Skip to content

Promote a bunch of Swift 3 compatibility access warnings to errors. #10086

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

Merged
merged 1 commit into from
Jun 16, 2017

Conversation

jrose-apple
Copy link
Contributor

This was done back in Swift 3.0.1 or 3.0.2. Let's finally make them errors in Swift 4!

I also fixed up a number of %error entries in diagnostics that can actually happen in invalid code. These are the ones that were already present in the warnings.

@jrose-apple jrose-apple requested a review from CodaFi June 3, 2017 03:01
@jrose-apple
Copy link
Contributor Author

@swift-ci Please test

This was done back in Swift 3.0.1 or 3.0.2. Let's finally make them
errors in Swift 4!

I also fixed up a number of '%error' entries in diagnostics that can
actually happen in invalid code. These are the ones that were already
present in the warnings.
@jrose-apple
Copy link
Contributor Author

@swift-ci Please test

@swift-ci
Copy link
Contributor

swift-ci commented Jun 3, 2017

Build failed
Jenkins build - Swift Test OS X Platform
Git Commit - 6a1b9580ee2aeabefbe947753015542b44412a1d
Test requested by - @jrose-apple

@swift-ci
Copy link
Contributor

swift-ci commented Jun 3, 2017

Build failed
Jenkins build - Swift Test Linux Platform
Git Commit - 6a1b9580ee2aeabefbe947753015542b44412a1d
Test requested by - @jrose-apple

Copy link
Contributor

@harlanhaskins harlanhaskins left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM -- wish there was a good way to test "this should be a warning in Swift 3 mode and an error in Swift 4"

@jrose-apple
Copy link
Contributor Author

Well, the text changed too, so I don't feel so bad. Thanks, Harlan!

Copy link
Contributor

@CodaFi CodaFi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@CodaFi
Copy link
Contributor

CodaFi commented Jun 15, 2017

@jtbandes Might also want to get in on this after his last big push for trapping in diagnostics.

@jtbandes
Copy link
Contributor

Can we add test cases for the “in this context” versions?

@jtbandes
Copy link
Contributor

(The point of %error was to crash so we could catch it in validation tests, but if these could happen, I guess they weren’t tested properly 😉)

@jrose-apple
Copy link
Contributor Author

Any places where they could happen before would always fall into the "warning" case; now that's no longer true. Yes, I can add more test cases, though maybe as a follow-up. (They only come up when you violate the model once and then reference that declaration.)

@najacque
Copy link
Contributor

@swift-ci please test

(borrowing this PR to test a test infrastructure issue)

@jrose-apple jrose-apple merged commit 970073a into swiftlang:master Jun 16, 2017
@jrose-apple jrose-apple deleted the access-denied branch June 16, 2017 18:47
jrose-apple added a commit to jrose-apple/swift that referenced this pull request Jun 16, 2017
…wiftlang#10086)

This was done back in Swift 3.0.1 or 3.0.2. Let's finally make them
errors in Swift 4!

I also fixed up a number of '%error' entries in diagnostics that can
actually happen in invalid code. These are the ones that were already
present in the warnings.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants