rust/tests/ui/async-await/in-trait/return-not-existing-type-wr...

18 lines
258 B
Rust

//@ edition:2021
struct Wrapper<T>(T);
trait Foo {
fn bar() -> Wrapper<Missing<impl Sized>>;
//~^ ERROR: cannot find type `Missing` in this scope [E0412]
}
impl Foo for () {
fn bar() -> Wrapper<i32> {
Wrapper(0)
}
}
fn main() {}