Skip to content

Conversation

saethlin
Copy link
Member

Fixes #109996

r? @bjorn3 because you commented that this situation could impact you as well

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels Apr 13, 2023
@rustbot
Copy link
Collaborator

rustbot commented Apr 13, 2023

Some changes occurred to MIR optimizations

cc @rust-lang/wg-mir-opt

@bjorn3
Copy link
Member

bjorn3 commented Apr 13, 2023

It's a bit of a hack, but I guess it works for now. You can't hit this on stable as you need #![no_core] and in addition skipping this check doesn't hurt correctness.

r=me with rustfmt applied

@oli-obk
Copy link
Contributor

oli-obk commented Apr 13, 2023

We should probably add a no-core test to our test suite that triggers this. Something like

#![feature(lang_items)]
#![feature(no_core)]
#![no_core]

#[lang = "sized"]
trait Foo {}

pub unsafe fn foo(x: *const i32) -> &'static i32 { unsafe { &*x } }

@saethlin saethlin force-pushed the check-panics-before-alignment branch from 8af5138 to 4061eb5 Compare April 13, 2023 14:58
@oli-obk
Copy link
Contributor

oli-obk commented Apr 13, 2023

@bors r=bjorn3

@bors
Copy link
Collaborator

bors commented Apr 13, 2023

📌 Commit 4061eb5 has been approved by bjorn3

It is now in the queue for this repository.

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Apr 13, 2023
bors added a commit to rust-lang-ci/rust that referenced this pull request Apr 13, 2023
…iaskrgr

Rollup of 8 pull requests

Successful merges:

 - rust-lang#109036 (Fix diff option conflict in UI test)
 - rust-lang#110193 (Check for body owner fallibly in error reporting)
 - rust-lang#110233 (Make rust-intrinsic ABI unwindable)
 - rust-lang#110259 (Added diagnostic for pin! macro in addition to Box::pin if Unpin isn't implemented)
 - rust-lang#110265 (Automatically update the LLVM submodule for musl target (and other places))
 - rust-lang#110277 (dead-code-lint: de-dup multiple unused assoc functions)
 - rust-lang#110283 (Only emit alignment checks if we have a panic_impl)
 - rust-lang#110291 (Implement `Copy` for `LocationDetail`)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
@bors bors merged commit c140e25 into rust-lang:master Apr 13, 2023
@rustbot rustbot added this to the 1.70.0 milestone Apr 13, 2023
@saethlin saethlin deleted the check-panics-before-alignment branch April 15, 2023 19:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

i686-pc-windows-gnu fails to compile rsbegin
5 participants