]> git.lizzy.rs Git - rust.git/blob - src/test/ui/traits/impl_trait_as_trait_return_position.rs
:arrow_up: rust-analyzer
[rust.git] / src / test / ui / traits / impl_trait_as_trait_return_position.rs
1 // check-pass
2
3 trait A {
4     type Foo;
5 }
6
7 impl<T> A for T {
8     type Foo = ();
9 }
10
11 fn foo() -> impl std::borrow::Borrow<<u8 as A>::Foo> {
12     ()
13 }
14
15 fn main() {
16     foo();
17 }