I tried this code:
fn foo<T>() {
const { panic!() }
}
// uncommenting this line makes it compile
// #[inline]
pub fn wut() {
foo::<i32>();
}
I expected #[inline] to not affect whether the code compiles or not. However, the code compiles with #[inline], and fails to compile without #[inline]. I'm not sure if this is a bug or not.
Discovered in #144363
@rustbot labels +A-const-eval
Meta
Reproducible on the playground with stable rust 1.88.0
I tried this code:
I expected
#[inline]to not affect whether the code compiles or not. However, the code compiles with#[inline], and fails to compile without#[inline]. I'm not sure if this is a bug or not.Discovered in #144363
@rustbot labels +A-const-eval
Meta
Reproducible on the playground with stable rust 1.88.0