1 error: lifetime may not live long enough
2 --> $DIR/type-check-pointer-comparisons.rs:6:5
4 LL | fn compare_const<'a, 'b>(x: *const &mut &'a i32, y: *const &mut &'b i32) {
5 | -- -- lifetime `'b` defined here
7 | lifetime `'a` defined here
9 | ^ requires that `'a` must outlive `'b`
11 = help: consider adding the following bound: `'a: 'b`
13 error: lifetime may not live long enough
14 --> $DIR/type-check-pointer-comparisons.rs:6:10
16 LL | fn compare_const<'a, 'b>(x: *const &mut &'a i32, y: *const &mut &'b i32) {
17 | -- -- lifetime `'b` defined here
19 | lifetime `'a` defined here
21 | ^ requires that `'b` must outlive `'a`
23 = help: consider adding the following bound: `'b: 'a`
25 help: `'a` and `'b` must be the same: replace one with the other
27 error: lifetime may not live long enough
28 --> $DIR/type-check-pointer-comparisons.rs:12:5
30 LL | fn compare_mut<'a, 'b>(x: *mut &'a i32, y: *mut &'b i32) {
31 | -- -- lifetime `'b` defined here
33 | lifetime `'a` defined here
35 | ^ requires that `'a` must outlive `'b`
37 = help: consider adding the following bound: `'a: 'b`
39 error: lifetime may not live long enough
40 --> $DIR/type-check-pointer-comparisons.rs:12:10
42 LL | fn compare_mut<'a, 'b>(x: *mut &'a i32, y: *mut &'b i32) {
43 | -- -- lifetime `'b` defined here
45 | lifetime `'a` defined here
47 | ^ requires that `'b` must outlive `'a`
49 = help: consider adding the following bound: `'b: 'a`
51 help: `'a` and `'b` must be the same: replace one with the other
53 error: lifetime may not live long enough
54 --> $DIR/type-check-pointer-comparisons.rs:18:5
56 LL | fn compare_fn_ptr<'a, 'b, 'c>(f: fn(&'c mut &'a i32), g: fn(&'c mut &'b i32)) {
57 | -- -- lifetime `'b` defined here
59 | lifetime `'a` defined here
61 | ^ requires that `'a` must outlive `'b`
63 = help: consider adding the following bound: `'a: 'b`
65 error: lifetime may not live long enough
66 --> $DIR/type-check-pointer-comparisons.rs:18:10
68 LL | fn compare_fn_ptr<'a, 'b, 'c>(f: fn(&'c mut &'a i32), g: fn(&'c mut &'b i32)) {
69 | -- -- lifetime `'b` defined here
71 | lifetime `'a` defined here
73 | ^ requires that `'b` must outlive `'a`
75 = help: consider adding the following bound: `'b: 'a`
77 help: `'a` and `'b` must be the same: replace one with the other
79 error: aborting due to 6 previous errors