]> git.lizzy.rs Git - rust.git/blob - src/tools/rustfmt/tests/target/existential_type.rs
Merge commit '39683d8eb7a32a74bea96ecbf1e87675d3338506' into sync_cg_gcc-2022-03-26
[rust.git] / src / tools / rustfmt / tests / target / existential_type.rs
1 // Opaque type.
2
3 #![feature(type_alias_impl_trait)]
4
5 pub type Adder<F, T>
6 where
7     T: Clone,
8     F: Copy,
9 = impl Fn(T) -> T;
10
11 pub type Adderrr<T> = impl Fn(T) -> T;
12
13 impl Foo for Bar {
14     type E = impl Trait;
15 }
16
17 pub type Adder_without_impl<F, T>
18 where
19     T: Clone,
20     F: Copy,
21 = Fn(T) -> T;
22
23 pub type Adderrr_without_impl<T> = Fn(T) -> T;