rust/tests/ui/impl-trait/in-trait/dump.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

16 lines
283 B
Rust
Raw Normal View History

//@ compile-flags: -Zverbose-internals
2025-03-06 20:50:51 +00:00
#![feature(rustc_attrs)]
#![rustc_hidden_type_of_opaques]
trait Foo {
fn hello(&self) -> impl Sized;
}
fn hello<'s, T: Foo>(x: &'s T) -> impl Sized + use<'s, T> {
//~^ ERROR <T as Foo>::{synthetic#0}<'s/#1>
x.hello()
}
fn main() {}