-
Notifications
You must be signed in to change notification settings - Fork 12.7k
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
Lifetime variance fixes for rustc #97292
Conversation
Some changes occured to the CTFE / Miri engine cc @rust-lang/miri Some changes occured to the CTFE / Miri engine cc @rust-lang/miri |
r? @davidtwco (rust-highfive has picked a reviewer for you, use r? to override) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not familiar with all of the parts of the compiler this changes, but this seems fairly straigthforward so LGTM.
@bors r+ |
📌 Commit 1784634 has been approved by |
Rollup of 4 pull requests Successful merges: - rust-lang#96129 (Document rounding for floating-point primitive operations and string parsing) - rust-lang#97286 (Add new eslint rule to prevent whitespace before function call paren) - rust-lang#97292 (Lifetime variance fixes for rustc) - rust-lang#97309 (Add some regression tests for rust-lang#90400) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
#97287 migrates rustc to a
Ty
type that is invariant over its lifetime'tcx
, so I need to fix a bunch of places that assume thatTy<'a>
andTy<'b>
can be unified by shortening both to some common lifetime.This is doable, since many lifetimes are already
'tcx
, so all this PR does is be a bit more explicit that elided lifetimes are actually'tcx
.Split out from #97287 so the compiler team can review independently.