2022-02-07 22:58:30 +01:00
|
|
|
warning: unnecessary lifetime parameter `'a`
|
2023-11-27 21:54:03 +00:00
|
|
|
--> $DIR/regions-static-bound-rpass.rs:5:17
|
2022-02-07 22:58:30 +01:00
|
|
|
|
|
2023-11-27 21:54:03 +00:00
|
|
|
LL | fn invariant_id<'a,'b>(t: &'b mut &'static ()) -> &'b mut &'a ()
|
|
|
|
| ^^
|
2022-02-07 22:58:30 +01:00
|
|
|
|
|
2023-11-27 21:54:03 +00:00
|
|
|
= note: you can use the `'static` lifetime directly, in place of `'a`
|
2023-02-22 09:41:48 +08:00
|
|
|
note: the lint level is defined here
|
|
|
|
--> $DIR/regions-static-bound-rpass.rs:3:9
|
|
|
|
|
|
2023-12-16 01:58:26 +00:00
|
|
|
LL | #![warn(redundant_lifetimes)]
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^
|
2022-02-07 22:58:30 +01:00
|
|
|
|
|
|
|
warning: unnecessary lifetime parameter `'a`
|
2023-11-27 21:54:03 +00:00
|
|
|
--> $DIR/regions-static-bound-rpass.rs:9:14
|
2022-02-07 22:58:30 +01:00
|
|
|
|
|
2023-11-27 21:54:03 +00:00
|
|
|
LL | fn static_id<'a>(t: &'a ()) -> &'static ()
|
|
|
|
| ^^
|
2022-02-07 22:58:30 +01:00
|
|
|
|
|
2023-11-27 21:54:03 +00:00
|
|
|
= note: you can use the `'static` lifetime directly, in place of `'a`
|
|
|
|
|
|
|
|
warning: unnecessary lifetime parameter `'a`
|
|
|
|
--> $DIR/regions-static-bound-rpass.rs:13:23
|
|
|
|
|
|
|
|
|
LL | fn static_id_indirect<'a,'b>(t: &'a ()) -> &'static ()
|
|
|
|
| ^^
|
|
|
|
|
|
|
|
|
= note: you can use the `'static` lifetime directly, in place of `'a`
|
2022-02-07 22:58:30 +01:00
|
|
|
|
|
|
|
warning: unnecessary lifetime parameter `'b`
|
2023-11-27 21:54:03 +00:00
|
|
|
--> $DIR/regions-static-bound-rpass.rs:13:26
|
2022-02-07 22:58:30 +01:00
|
|
|
|
|
2023-11-27 21:54:03 +00:00
|
|
|
LL | fn static_id_indirect<'a,'b>(t: &'a ()) -> &'static ()
|
|
|
|
| ^^
|
2022-02-07 22:58:30 +01:00
|
|
|
|
|
2023-11-27 21:54:03 +00:00
|
|
|
= note: you can use the `'static` lifetime directly, in place of `'b`
|
2022-02-07 22:58:30 +01:00
|
|
|
|
2023-11-27 21:54:03 +00:00
|
|
|
warning: 4 warnings emitted
|
2022-02-07 22:58:30 +01:00
|
|
|
|