]> git.proxmox.com Git - rustc.git/blob - src/test/ui/type-alias-impl-trait/not_well_formed.rs
New upstream version 1.52.0~beta.3+dfsg1
[rustc.git] / src / test / ui / type-alias-impl-trait / not_well_formed.rs
1 // revisions: min_tait full_tait
2 #![feature(min_type_alias_impl_trait)]
3 #![cfg_attr(full_tait, feature(type_alias_impl_trait))]
4 //[full_tait]~^ WARN incomplete
5
6 fn main() {
7 }
8
9 trait TraitWithAssoc {
10 type Assoc;
11 }
12
13 type Foo<V> = impl Trait<V::Assoc>; //~ associated type `Assoc` not found for `V`
14
15 trait Trait<U> {}
16
17 impl<W> Trait<W> for () {}
18
19 fn foo_desugared<T: TraitWithAssoc>(_: T) -> Foo<T> {
20 ()
21 }