-
Notifications
You must be signed in to change notification settings - Fork 13.2k
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
[beta] Backports #47943
[beta] Backports #47943
Conversation
We can't use git commands to compute a prerelease version when we're building from a source tarball, or if git is otherwise unavailable. We'll just call such builds `x.y.z-beta`, without a prerelease.
MIR's `Const::get_field()` attempts to retrieve the value for a given field in a constant. In the case of a union constant it was falling through to a generic `const_get_elt` based on the field index. As union fields don't have an index this caused an ICE in `llvm_field_index`. Fix by simply returning the current value when accessing any field in a union. This works because all union fields start at byte offset 0. The added test uses `const_fn` it ensure the field is extracted using MIR's const evaluation. The crash is reproducible without it, however. Fixes rust-lang#47788
r? @pnkfelix (rust_highfive has picked a reviewer for you, use r? to override) |
@bors r+ p=10 |
📌 Commit 06e74a9 has been approved by |
I'm gonna sneak a Cargo update in here while I can 🔍 @bors: r=Mark-Simulacrum |
📌 Commit 0a33981 has been approved by |
💔 Test failed - status-appveyor |
⌛ Testing commit 0a33981 with merge f28b58bc2d4a7adda88e0b9e6ca78e529912084c... |
💔 Test failed - status-appveyor |
☀️ Test successful - status-appveyor, status-travis |
It seems that beta-nominated tags were not removed for those 7 beta-backported PRs: |
Can do, thanks so much again @MaloJaffre for the help with the backports! |
Cherry-picked into beta: