]> git.proxmox.com Git - rustc.git/blob - src/test/ui/generic-associated-types/issue-90014.rs
Update unsuspicious file list
[rustc.git] / src / test / ui / generic-associated-types / issue-90014.rs
1 // edition:2018
2
3 #![feature(type_alias_impl_trait)]
4
5 use std::future::Future;
6
7 trait MakeFut {
8 type Fut<'a> where Self: 'a;
9 fn make_fut<'a>(&'a self) -> Self::Fut<'a>;
10 }
11
12 impl MakeFut for &'_ mut () {
13 type Fut<'a> = impl Future<Output = ()>;
14 //~^ ERROR: the type `&mut ()` does not fulfill the required lifetime
15
16 fn make_fut<'a>(&'a self) -> Self::Fut<'a> {
17 async { () }
18 }
19 }
20
21 fn main() {}