1
Fork 0

Walk return-position impl trait in trait deeply in associated_item_def_ids

This commit is contained in:
Michael Goulet 2023-03-21 18:06:04 +00:00 committed by Santiago Pastorino
parent 478cbb42b7
commit 76b0cf812b
No known key found for this signature in database
GPG key ID: 8131A24E0C79EFAF
3 changed files with 36 additions and 22 deletions

View file

@ -2,12 +2,13 @@
#![feature(return_position_impl_trait_in_trait)]
use std::ops::Deref;
pub trait Foo {
fn bar() -> impl Sized;
fn bar() -> impl Deref<Target = impl Sized>;
}
pub struct Foreign;
impl Foo for Foreign {
fn bar() {}
fn bar() -> &'static () { &() }
}