]> git.lizzy.rs Git - rust.git/blob - tests/ui/type-alias-impl-trait/bound_reduction2.rs
Rollup merge of #106323 - starkat99:stabilize-f16c_target_feature, r=petrochenkov
[rust.git] / tests / 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 }