rust/tests/ui/async-await/issues/issue-63388-1.rs

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

20 lines
261 B
Rust
Raw Normal View History

//@ edition:2018
struct Xyz {
a: u64,
}
trait Foo {}
impl Xyz {
async fn do_sth<'a>(
&'a self, foo: &dyn Foo
2019-10-02 13:17:38 -05:00
) -> &dyn Foo
{
2022-04-01 12:13:25 -05:00
//~^ ERROR explicit lifetime required in the type of `foo` [E0621]
2022-05-21 14:46:25 -05:00
foo
}
}
fn main() {}