]> git.proxmox.com Git - rustc.git/blame - src/test/ui/type-alias-impl-trait/bound_reduction2.rs
New upstream version 1.52.0~beta.3+dfsg1
[rustc.git] / src / test / ui / type-alias-impl-trait / bound_reduction2.rs
CommitLineData
6a06907d
XL
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
0531ce1d 5
1b1a35ee 6fn main() {}
8faf50e0
XL
7
8trait TraitWithAssoc {
9 type Assoc;
10}
11
416331ca 12type Foo<V> = impl Trait<V>;
8faf50e0
XL
13
14trait Trait<U> {}
0531ce1d 15
8faf50e0 16impl<W> Trait<W> for () {}
0531ce1d 17
ba9703b0 18fn foo_desugared<T: TraitWithAssoc>(_: T) -> Foo<T::Assoc> {
1b1a35ee 19 //~^ ERROR non-defining opaque type use in defining scope
8faf50e0 20 ()
54a0048b 21}