Closed
Conversation
In our type inference system, when we "generalize" a type T to become a suitable value for a type variable V, we sometimes wind up creating new inference variables. So, for example, if we are making V be some subtype of `&'X u32`, then we might instantiate V with `&'Y u32`. This generalized type is then related `&'Y u32 <: &'X u32`, resulting in a region constriant `'Y: 'X`. Previously, however, we were making these fresh variables like `'Y` in the "current universe", but they should be created in the universe of V. Moreover, we sometimes cheat in an invariant context and avoid creating fresh variables if we know the result must be equal -- we can only do that when the universes work out.
This set of diffs was produced by combing through b68fad6 and seeing where the `leak_check` used to be invoked and how.
One surprise: old-lub-glb-object.rs, may indicate a bug
This preserves the error you currently get on stable for the old-lub-glb-object.rs test.
This comment has been minimized.
This comment has been minimized.
Contributor
|
Contributor
Member
|
Can you rollup (cherry-picking) all the other beta-accepted PRs with this one? r=me when you do that |
Member
|
We'll probably roll this up with one or two other backports, so not yet approving this PR. |
Contributor
Author
|
@bors try |
Collaborator
Contributor
Author
|
Not sure if try is a good idea or not, but I know we had talked about crater runs, so might as well get started just in case? |
Member
|
I don't think we want/need a crater run here - the one on master should be sufficient. |
Collaborator
|
☀️ Test successful - checks-travis |
Contributor
Author
|
@Mark-Simulacrum ok, then this is ready to go, and I leave it to you to decide how/when to merge |
Contributor
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Backport of #58592 and #58056 to beta.