blob: 7c7411651d033752a5dacdfa369c158157b12eac (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
|
error: lifetime flowing from input to output with different syntax can be confusing
--> $DIR/example-from-issue48686.rs:6:21
|
LL | pub fn get_mut(&'static self, x: &mut u8) -> &mut u8 {
| ^^^^^^^ ------- the lifetime gets resolved as `'static`
| |
| this lifetime flows to the output
|
note: the lint level is defined here
--> $DIR/example-from-issue48686.rs:1:9
|
LL | #![deny(mismatched_lifetime_syntaxes)]
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
help: one option is to consistently use `'static`
|
LL | pub fn get_mut(&'static self, x: &mut u8) -> &'static mut u8 {
| +++++++
error: aborting due to 1 previous error
|