rust/tests/ui/explicit-tail-calls/callee_is_track_caller_polymorphic.rs
2025-08-13 02:26:52 +02:00

21 lines
332 B
Rust

//@ run-pass
//@ ignore-pass
#![expect(incomplete_features)]
#![feature(explicit_tail_calls)]
fn c<T: Trait>() {
become T::f();
//~^ warning: tail calling a function marked with `#[track_caller]` has no special effect
}
trait Trait {
#[track_caller]
fn f() {}
}
impl Trait for () {}
fn main() {
c::<()>();
}