-
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
ICE: Got a scalar pair where a scalar was expected
#121363
Comments
Can you try re-bisecting with |
with |
Good, that's what I expected. What does this bisect to? struct TwoStrs(str, str) where str: Sized;
impl ::core::fmt::Debug for TwoStrs where str: Sized {
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_tuple_field2_finish(f, "TwoStrs",
&self.0, &&self.1)
}
} (I just expanded your example and deleted the |
with |
Whatever minimization you do should always try to turn off as many MIR optimizations as possible. The machine-accessible thing is to lower the Bisecting with
|
To be clear, the reason you should try to do this is that the MIR optimization pipeline gets tweaked constantly, so if you just turn on all MIR optimizations possible, the bisection can easily get confused because among other things, the behavior of the inliner can fluctuate from nightly to nightly, even if the MIR optimization code wasn't changed. Minimizing or eliminating the MIR optimizations involved in the reproducer helps with that effect a lot. |
I have not been able to crash it with |
That's odd. I can crash godbolt: https://godbolt.org/z/haMGExKM6 |
ah you made it a pub struct! |
#![feature(trivial_bounds)]
#[derive(Debug)]
pub struct TwoStrs(str, str)
where
str: Sized; with Regression in nightly-2022-12-11 |
Ah. I'm in the habit of making things |
auto-reduced (treereduce-rust):
original:
Version information
Command:
/home/matthias/.rustup/toolchains/master/bin/rustc -Zmir-opt-level=5 -Zcrate-attr=feature(trivial_bounds) --crate-type=lib
Program output
The text was updated successfully, but these errors were encountered: