1
Fork 0

Make nested RPITIT inherit the parent opaque's generics.

This commit is contained in:
Camille GILLOT 2022-12-04 14:18:52 +00:00
parent cab4fd678c
commit e2d41f4c97
2 changed files with 18 additions and 15 deletions

View file

@ -0,0 +1,17 @@
// check-pass
// edition: 2021
#![feature(async_fn_in_trait)]
#![feature(return_position_impl_trait_in_trait)]
#![allow(incomplete_features)]
use std::future::Future;
use std::marker::PhantomData;
trait Lockable<K, V> {
async fn lock_all_entries(&self) -> impl Future<Output = Guard<'_>>;
}
struct Guard<'a>(PhantomData<&'a ()>);
fn main() {}