summaryrefslogtreecommitdiffstats
path: root/tests/ui/impl-trait/in-trait/deep-match-works.rs
blob: fc290f11f9d9c2e1d6b45f043e7a9f3a6ce922c9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
// check-pass

#![feature(return_position_impl_trait_in_trait, lint_reasons)]
#![allow(incomplete_features)]

pub struct Wrapper<T>(T);

pub trait Foo {
    fn bar() -> Wrapper<impl Sized>;
}

impl Foo for () {
    #[expect(refining_impl_trait)]
    fn bar() -> Wrapper<i32> {
        Wrapper(0)
    }
}

fn main() {}