rust/tests/ui/impl-trait/in-trait/async-and-ret-ref.rs

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

12 lines
221 B
Rust
Raw Normal View History

//@ edition:2021
// https://github.com/rust-lang/rust/issues/117547
trait T {}
trait MyTrait {
async fn foo() -> &'static impl T;
2024-02-27 10:11:35 -06:00
//~^ ERROR the associated type `impl T` may not live long enough
}
fn main() {}