-
Notifications
You must be signed in to change notification settings - Fork 10.5k
[CSGen] SR-3668 fix for 3.1 branch #7004
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
[CSGen] SR-3668 fix for 3.1 branch #7004
Conversation
Adding the fix for SR-3668 (exponential dictionary literal behavior) to the Swift 3.1 branch. Patch is identical to that already accepted in master (cc28774).
@swift-ci Please test |
drive by test. Not an endorsement. |
@swift-ci Please test |
Build failed |
I find the OS X failure rather disappointing and puzzling; from the console output it seems totally unrelated to my patch... By the way, I'm wondering if I can't actually invoke CI runs because I'm too new. I've seen nothing about this in your CI documentation, but such a policy would make sense to me; you don't want random people spamming the CI setup. Does that mean that for now I should hold off on sending CI messages? |
The macOS failure is a known issue. We'll look into it. |
@swift-ci Please test macOS |
Build failed |
The Clang issue should now be resolved. |
@swift-ci Please test macOS |
Build failed |
@swift-ci Please test macOS |
1 similar comment
@swift-ci Please test macOS |
Adding the fix for SR-3668 (exponential dictionary literal behavior) to
the Swift 3.1 branch. Patch is identical to that already accepted in
master (cc28774).
This is the same fix for bug SR-3668 already accepted in master. The bug prevents what should be already be valid Swift sources from compiling, because longer dictionary literals can be rejected purely due to expression complexity.
This is potentially a very annoying bug for users; indeed, I stumbled upon it myself while working on a project in Stanford's online iOS programming course, watching it grind my machine to a halt as both the compiler and SourceKitService choked on a similar expression. See SR-2102 for someone else encountering a similar situation; from his example he was clearly working on the same course.
The fix makes no change to the language and should be safe for Swift 3.1 (and perhaps even for Swift 3.0 if any further dot releases from that branch are planned). I have run the test and validation-test targets on my macOS system for the patch on the swift-3.1-branch, and it passes.
As well as referring to the bug report, see my original PR-6973 for master to get a more extended description and further discussion.
@tkremenek: notifying you as 3.1 release manager.
@DougGregor: notifying you again, since you reviewed PR-6973.
Resolves SR-3668.