]> git.lizzy.rs Git - rust.git/blob - src/test/ui/type-alias-impl-trait/bound_reduction2.rs
Rollup merge of #99064 - lyming2007:issue-97687-fix, r=estebank
[rust.git] / src / test / ui / type-alias-impl-trait / bound_reduction2.rs
1 #![feature(type_alias_impl_trait)]
2
3 fn main() {}
4
5 trait TraitWithAssoc {
6     type Assoc;
7 }
8
9 type Foo<V> = impl Trait<V>;
10
11 trait Trait<U> {}
12
13 impl<W> Trait<W> for () {}
14
15 fn foo_desugared<T: TraitWithAssoc>(_: T) -> Foo<T::Assoc> {
16     ()
17     //~^ ERROR non-defining opaque type use
18 }