]> git.proxmox.com Git - rustc.git/blob - tests/ui/impl-trait/issues/issue-77987.rs
New upstream version 1.68.2+dfsg1
[rustc.git] / tests / ui / impl-trait / issues / issue-77987.rs
1 #![feature(type_alias_impl_trait)]
2
3 // check-pass
4
5 trait Foo<T> {}
6 impl<T, U> Foo<T> for U {}
7
8 type Scope = impl Foo<()>;
9
10 #[allow(unused)]
11 fn infer_scope() -> Scope {
12 ()
13 }
14
15 #[allow(unused)]
16 fn ice() -> impl Foo<Scope>
17 {
18 loop {}
19 }
20
21 fn main() {}