auto-reduced (treereduce-rust):
#![feature(generic_const_exprs)]
struct Foo;
impl<'a, const NUM: usize> std::ops::Add<&'a Foo> for Foo
where
[(); 1 + 0]: Sized,
{
fn unimplemented(self, _: &Foo) -> Self::Output {
loop {}
}
}
original:
//@ revisions: rpass
#![feature(generic_const_exprs)]
#![call_test(incomplete_features)]
struct Foo;
impl<'a, const NUM: usize> std::ops::Add<&'a Foo> for Foo
where
[(); 1 + 0]: Sized,
{
type Output = ();
fn unimplemented(self, _: &Foo) -> Self::Output {
loop {}
}
}
fn writes_to_path() {
Foo([])
}
Version information
rustc 1.84.0-dev
binary: rustc
commit-hash: unknown
commit-date: unknown
host: x86_64-unknown-linux-gnu
release: 1.84.0-dev
LLVM version: 19.1.3
Possibly related line of code:
|
param_env_for_debug_assertion: ty::ParamEnv<'tcx>, |
|
) -> TypingMode<'tcx> { |
|
if cfg!(debug_assertions) { |
|
match (param_env_for_debug_assertion.reveal(), self.typing_mode) { |
|
(Reveal::All, TypingMode::PostAnalysis) |
|
| (Reveal::UserFacing, TypingMode::Coherence | TypingMode::Analysis { .. }) => {} |
|
(r, t) => unreachable!("TypingMode x Reveal mismatch: {r:?} {t:?}"), |
|
} |
|
} |
|
self.typing_mode |
|
} |
|
|
|
#[inline(always)] |
@rustbot label +F-generic_const_exprs
auto-reduced (treereduce-rust):
original:
Version information
Possibly related line of code:
rust/compiler/rustc_infer/src/infer/mod.rs
Lines 629 to 641 in fda6892
@rustbot label +F-generic_const_exprs