]> git.lizzy.rs Git - rust.git/blob - tests/ui/borrowck/regions-bound-missing-bound-in-impl.stderr
Rollup merge of #106726 - cmorin6:fix-comment-typos, r=Nilstrieb
[rust.git] / tests / ui / borrowck / regions-bound-missing-bound-in-impl.stderr
1 error[E0195]: lifetime parameters or bounds on method `no_bound` do not match the trait declaration
2   --> $DIR/regions-bound-missing-bound-in-impl.rs:19:16
3    |
4 LL |     fn no_bound<'b>(self, b: Inv<'b>);
5    |                ---- lifetimes in impl do not match this method in trait
6 ...
7 LL |     fn no_bound<'b:'a>(self, b: Inv<'b>) {
8    |                ^^^^^^^ lifetimes do not match method in trait
9
10 error[E0195]: lifetime parameters or bounds on method `has_bound` do not match the trait declaration
11   --> $DIR/regions-bound-missing-bound-in-impl.rs:23:17
12    |
13 LL |     fn has_bound<'b:'a>(self, b: Inv<'b>);
14    |                 ------- lifetimes in impl do not match this method in trait
15 ...
16 LL |     fn has_bound<'b>(self, b: Inv<'b>) {
17    |                 ^^^^ lifetimes do not match method in trait
18
19 error[E0308]: method not compatible with trait
20   --> $DIR/regions-bound-missing-bound-in-impl.rs:27:5
21    |
22 LL |     fn wrong_bound1<'b,'c,'d:'a+'c>(self, b: Inv<'b>, c: Inv<'c>, d: Inv<'d>) {
23    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ lifetime mismatch
24    |
25    = note: expected signature `fn(&'a isize, Inv<'c>, Inv<'c>, Inv<'_>)`
26               found signature `fn(&'a isize, Inv<'_>, Inv<'c>, Inv<'_>)`
27 note: the lifetime `'c` as defined here...
28   --> $DIR/regions-bound-missing-bound-in-impl.rs:27:24
29    |
30 LL |     fn wrong_bound1<'b,'c,'d:'a+'c>(self, b: Inv<'b>, c: Inv<'c>, d: Inv<'d>) {
31    |                        ^^
32 note: ...does not necessarily outlive the lifetime `'c` as defined here
33   --> $DIR/regions-bound-missing-bound-in-impl.rs:27:24
34    |
35 LL |     fn wrong_bound1<'b,'c,'d:'a+'c>(self, b: Inv<'b>, c: Inv<'c>, d: Inv<'d>) {
36    |                        ^^
37
38 error[E0308]: method not compatible with trait
39   --> $DIR/regions-bound-missing-bound-in-impl.rs:27:5
40    |
41 LL |     fn wrong_bound1<'b,'c,'d:'a+'c>(self, b: Inv<'b>, c: Inv<'c>, d: Inv<'d>) {
42    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ lifetime mismatch
43    |
44    = note: expected signature `fn(&'a isize, Inv<'c>, Inv<'c>, Inv<'_>)`
45               found signature `fn(&'a isize, Inv<'_>, Inv<'c>, Inv<'_>)`
46 note: the lifetime `'c` as defined here...
47   --> $DIR/regions-bound-missing-bound-in-impl.rs:27:24
48    |
49 LL |     fn wrong_bound1<'b,'c,'d:'a+'c>(self, b: Inv<'b>, c: Inv<'c>, d: Inv<'d>) {
50    |                        ^^
51 note: ...does not necessarily outlive the lifetime `'c` as defined here
52   --> $DIR/regions-bound-missing-bound-in-impl.rs:27:24
53    |
54 LL |     fn wrong_bound1<'b,'c,'d:'a+'c>(self, b: Inv<'b>, c: Inv<'c>, d: Inv<'d>) {
55    |                        ^^
56
57 error[E0195]: lifetime parameters or bounds on method `wrong_bound2` do not match the trait declaration
58   --> $DIR/regions-bound-missing-bound-in-impl.rs:42:20
59    |
60 LL |     fn wrong_bound2<'b,'c,'d:'a+'b>(self, b: Inv<'b>, c: Inv<'c>, d: Inv<'d>);
61    |                    ---------------- lifetimes in impl do not match this method in trait
62 ...
63 LL |     fn wrong_bound2(self, b: Inv, c: Inv, d: Inv) {
64    |                    ^ lifetimes do not match method in trait
65
66 error[E0276]: impl has stricter requirements than trait
67   --> $DIR/regions-bound-missing-bound-in-impl.rs:49:26
68    |
69 LL |     fn another_bound<'x: 'a>(self, x: Inv<'x>, y: Inv<'t>);
70    |     ------------------------------------------------------- definition of `another_bound` from trait
71 ...
72 LL |     fn another_bound<'x: 't>(self, x: Inv<'x>, y: Inv<'t>) {
73    |                          ^^ impl has extra requirement `'x: 't`
74
75 error: aborting due to 6 previous errors
76
77 Some errors have detailed explanations: E0195, E0276, E0308.
78 For more information about an error, try `rustc --explain E0195`.