2024-02-16 20:02:50 +00:00
|
|
|
//@ edition: 2021
|
2023-10-16 15:39:07 +00:00
|
|
|
|
|
|
|
use std::future::Future;
|
|
|
|
|
|
|
|
trait Trait {
|
|
|
|
type Gat<'a>;
|
|
|
|
//~^ ERROR missing required bound on `Gat`
|
|
|
|
async fn foo(&self) -> Self::Gat<'_>;
|
|
|
|
}
|
|
|
|
|
|
|
|
trait Trait2 {
|
|
|
|
type Gat<'a>;
|
|
|
|
//~^ ERROR missing required bound on `Gat`
|
|
|
|
async fn foo(&self) -> impl Future<Output = Self::Gat<'_>>;
|
|
|
|
}
|
|
|
|
|
|
|
|
fn main() {}
|