]> git.proxmox.com Git - rustc.git/blame - src/tools/rustfmt/tests/target/type_alias.rs
Update upstream source from tag 'upstream/1.52.1+dfsg1'
[rustc.git] / src / tools / rustfmt / tests / target / type_alias.rs
CommitLineData
f20569fa
XL
1// rustfmt-normalize_comments: true
2
3type PrivateTest<'a, I> = (
4 Box<Parser<Input = I, Output = char> + 'a>,
5 Box<Parser<Input = I, Output = char> + 'a>,
6);
7
8pub type PublicTest<'a, I, O> = Result<
9 Vec<MyLongType>,
10 Box<Parser<Input = I, Output = char> + 'a>,
11 Box<Parser<Input = I, Output = char> + 'a>,
12>;
13
14pub type LongGenericListTest<
15 'a,
16 'b,
17 'c,
18 'd,
19 LONGPARAMETERNAME,
20 LONGPARAMETERNAME,
21 LONGPARAMETERNAME,
22 A,
23 B,
24 C,
25> = Option<Vec<MyType>>;
26
27pub type Exactly100CharsTest<'a, 'b, 'c, 'd, LONGPARAMETERNAME, LONGPARAMETERNAME, A, B> = Vec<i32>;
28
29pub type Exactly101CharsTest<'a, 'b, 'c, 'd, LONGPARAMETERNAME, LONGPARAMETERNAME, A, B> =
30 Vec<Test>;
31
32pub type Exactly100CharsToEqualTest<'a, 'b, 'c, 'd, LONGPARAMETERNAME, LONGPARAMETERNAME, A, B, C> =
33 Vec<i32>;
34
35pub type GenericsFitButNotEqualTest<
36 'a,
37 'b,
38 'c,
39 'd,
40 LONGPARAMETERNAME,
41 LONGPARAMETERNAME,
42 A1,
43 B,
44 C,
45> = Vec<i32>;
46
47pub type CommentTest<
48 // Lifetime
49 'a,
50 // Type
51 T,
52> = ();
53
54pub type WithWhereClause<LONGPARAMETERNAME, T>
55where
56 T: Clone,
57 LONGPARAMETERNAME: Clone + Eq + OtherTrait,
58= Option<T>;
59
60pub type Exactly100CharstoEqualWhereTest<T, U, PARAMET>
61where
62 T: Clone + Ord + Eq + SomeOtherTrait,
63= Option<T>;
64
65pub type Exactly101CharstoEqualWhereTest<T, U, PARAMETE>
66where
67 T: Clone + Ord + Eq + SomeOtherTrait,
68= Option<T>;
69
70type RegisterPlugin = unsafe fn(pt: *const c_char, plugin: *mut c_void, data: *mut CallbackData);
71
72// #1683
73pub type Between<Lhs, Rhs> =
74 super::operators::Between<Lhs, super::operators::And<AsExpr<Rhs, Lhs>, AsExpr<Rhs, Lhs>>>;
75pub type NotBetween<Lhs, Rhs> =
76 super::operators::NotBetween<Lhs, super::operators::And<AsExpr<Rhs, Lhs>, AsExpr<Rhs, Lhs>>>;