Skip to content
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

[3.1] [Constraint solver] Dont assume orphans are along in the inactive list. #7741

Merged
merged 1 commit into from Feb 24, 2017

Conversation

DougGregor
Copy link
Member

@DougGregor DougGregor commented Feb 24, 2017

Explanation: The inactive list may contain other disjunctions associated with bound
type variables, which will cause the constraint solver to crash.

Scope: The crash showed up with a fairly simple expression involving ?. and ??, so it could potentially hit a significant amount of code. The code causing the crash is fairly new (merged on Monday).

SR Issue: https://bugs.swift.org/browse/SR-4056
rdar://problem/30686926

Risk: Fairly low; it's a small "obvious" change to the orphan-constraint-handling code.

Testing: Compiler regression testing, plus the example from the fixed SR.

The inactive list may contain other disjunctions associated with bound
type variables. For now, make sure we recover the orphan directly to
fix the crash in SR-4056 / rdar://problem/30686926. Later, we can
treat these as orphans, too.

(cherry picked from commit 99a1396)
@DougGregor DougGregor added this to the Swift 3.1 milestone Feb 24, 2017
@DougGregor
Copy link
Member Author

@swift-ci please test

@tkremenek tkremenek merged commit 7e1648c into apple:swift-3.1-branch Feb 24, 2017
@rudkx
Copy link
Member

rudkx commented Feb 24, 2017

LGTM!

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.

None yet

3 participants