]> git.proxmox.com Git - rustc.git/blame - src/test/ui/type-alias-impl-trait/issue-57611-trait-alias.min_tait.stderr
Merge tag 'debian/1.52.1+dfsg1-1_exp2' into proxmox/buster
[rustc.git] / src / test / ui / type-alias-impl-trait / issue-57611-trait-alias.min_tait.stderr
CommitLineData
6a06907d
XL
1error: implementation of `FnOnce` is not general enough
2 --> $DIR/issue-57611-trait-alias.rs:20:16
3 |
4LL | type Bar = impl Baz<Self, Self>;
5 | ^^^^^^^^^^^^^^^^^^^^ implementation of `FnOnce` is not general enough
6 |
7 = note: closure with signature `fn(&'2 X) -> &X` must implement `FnOnce<(&'1 X,)>`, for any lifetime `'1`...
8 = note: ...but it actually implements `FnOnce<(&'2 X,)>`, for some specific lifetime `'2`
9
10error[E0308]: mismatched types
11 --> $DIR/issue-57611-trait-alias.rs:20:16
12 |
13LL | type Bar = impl Baz<Self, Self>;
14 | ^^^^^^^^^^^^^^^^^^^^ one type is more general than the other
15 |
16 = note: expected type `for<'r> Fn<(&'r X,)>`
17 found type `Fn<(&'<empty> X,)>`
18note: this closure does not fulfill the lifetime requirements
19 --> $DIR/issue-57611-trait-alias.rs:28:9
20 |
21LL | |x| x
22 | ^^^^^
23
24error: implementation of `FnOnce` is not general enough
25 --> $DIR/issue-57611-trait-alias.rs:20:16
26 |
27LL | type Bar = impl Baz<Self, Self>;
28 | ^^^^^^^^^^^^^^^^^^^^ implementation of `FnOnce` is not general enough
29 |
30 = note: closure with signature `fn(&'2 X) -> &'2 X` must implement `FnOnce<(&'1 X,)>`, for any lifetime `'1`...
31 = note: ...but it actually implements `FnOnce<(&'2 X,)>`, for some specific lifetime `'2`
32
33error[E0308]: mismatched types
34 --> $DIR/issue-57611-trait-alias.rs:20:16
35 |
36LL | type Bar = impl Baz<Self, Self>;
37 | ^^^^^^^^^^^^^^^^^^^^ one type is more general than the other
38 |
39 = note: expected type `for<'r> Fn<(&'r X,)>`
40 found type `Fn<(&'<empty> X,)>`
41note: this closure does not fulfill the lifetime requirements
42 --> $DIR/issue-57611-trait-alias.rs:28:9
43 |
44LL | |x| x
45 | ^^^^^
46
47error: implementation of `FnOnce` is not general enough
48 --> $DIR/issue-57611-trait-alias.rs:20:16
49 |
50LL | type Bar = impl Baz<Self, Self>;
51 | ^^^^^^^^^^^^^^^^^^^^ implementation of `FnOnce` is not general enough
52 |
53 = note: closure with signature `fn(&'2 X) -> &'2 X` must implement `FnOnce<(&'1 X,)>`, for any lifetime `'1`...
54 = note: ...but it actually implements `FnOnce<(&'2 X,)>`, for some specific lifetime `'2`
55
56error: aborting due to 5 previous errors
57
58For more information about this error, try `rustc --explain E0308`.