2022-12-01 11:29:38 -06:00
|
|
|
error: getter function appears to return the wrong field
|
|
|
|
--> $DIR/misnamed_getters.rs:11:5
|
|
|
|
|
|
|
|
|
LL | / fn a(&self) -> &u8 {
|
2023-08-24 14:32:12 -05:00
|
|
|
LL | |
|
|
|
|
LL | |
|
2022-12-01 11:29:38 -06:00
|
|
|
LL | | &self.b
|
|
|
|
| | ------- help: consider using: `&self.a`
|
|
|
|
LL | | }
|
|
|
|
| |_____^
|
|
|
|
|
|
|
|
|
= note: `-D clippy::misnamed-getters` implied by `-D warnings`
|
2023-08-01 07:02:21 -05:00
|
|
|
= help: to override `-D warnings` add `#[allow(clippy::misnamed_getters)]`
|
2022-12-01 11:29:38 -06:00
|
|
|
|
|
|
|
error: getter function appears to return the wrong field
|
2023-08-24 14:32:12 -05:00
|
|
|
--> $DIR/misnamed_getters.rs:16:5
|
2022-12-01 11:29:38 -06:00
|
|
|
|
|
|
|
|
LL | / fn a_mut(&mut self) -> &mut u8 {
|
2023-08-24 14:32:12 -05:00
|
|
|
LL | |
|
2022-12-01 11:29:38 -06:00
|
|
|
LL | | &mut self.b
|
|
|
|
| | ----------- help: consider using: `&mut self.a`
|
|
|
|
LL | | }
|
|
|
|
| |_____^
|
|
|
|
|
|
|
|
error: getter function appears to return the wrong field
|
2023-08-24 14:32:12 -05:00
|
|
|
--> $DIR/misnamed_getters.rs:21:5
|
2022-12-01 11:29:38 -06:00
|
|
|
|
|
|
|
|
LL | / fn b(self) -> u8 {
|
2023-08-24 14:32:12 -05:00
|
|
|
LL | |
|
2022-12-01 11:29:38 -06:00
|
|
|
LL | | self.a
|
|
|
|
| | ------ help: consider using: `self.b`
|
|
|
|
LL | | }
|
|
|
|
| |_____^
|
|
|
|
|
|
|
|
error: getter function appears to return the wrong field
|
2023-08-24 14:32:12 -05:00
|
|
|
--> $DIR/misnamed_getters.rs:26:5
|
2022-12-01 11:29:38 -06:00
|
|
|
|
|
|
|
|
LL | / fn b_mut(&mut self) -> &mut u8 {
|
2023-08-24 14:32:12 -05:00
|
|
|
LL | |
|
2022-12-01 11:29:38 -06:00
|
|
|
LL | | &mut self.a
|
|
|
|
| | ----------- help: consider using: `&mut self.b`
|
|
|
|
LL | | }
|
|
|
|
| |_____^
|
|
|
|
|
|
|
|
error: getter function appears to return the wrong field
|
2023-08-24 14:32:12 -05:00
|
|
|
--> $DIR/misnamed_getters.rs:31:5
|
2022-12-01 11:29:38 -06:00
|
|
|
|
|
|
|
|
LL | / fn c(&self) -> &u8 {
|
2023-08-24 14:32:12 -05:00
|
|
|
LL | |
|
2022-12-01 11:29:38 -06:00
|
|
|
LL | | &self.b
|
|
|
|
| | ------- help: consider using: `&self.c`
|
|
|
|
LL | | }
|
|
|
|
| |_____^
|
|
|
|
|
|
|
|
error: getter function appears to return the wrong field
|
2023-08-24 14:32:12 -05:00
|
|
|
--> $DIR/misnamed_getters.rs:36:5
|
2022-12-01 11:29:38 -06:00
|
|
|
|
|
|
|
|
LL | / fn c_mut(&mut self) -> &mut u8 {
|
2023-08-24 14:32:12 -05:00
|
|
|
LL | |
|
2022-12-01 11:29:38 -06:00
|
|
|
LL | | &mut self.a
|
|
|
|
| | ----------- help: consider using: `&mut self.c`
|
|
|
|
LL | | }
|
|
|
|
| |_____^
|
|
|
|
|
|
|
|
error: getter function appears to return the wrong field
|
2023-08-24 14:32:12 -05:00
|
|
|
--> $DIR/misnamed_getters.rs:48:5
|
2022-12-01 11:29:38 -06:00
|
|
|
|
|
|
|
|
LL | / unsafe fn a(&self) -> &u8 {
|
2023-08-24 14:32:12 -05:00
|
|
|
LL | |
|
2022-12-01 11:29:38 -06:00
|
|
|
LL | | &self.b
|
|
|
|
| | ------- help: consider using: `&self.a`
|
|
|
|
LL | | }
|
|
|
|
| |_____^
|
|
|
|
|
|
|
|
error: getter function appears to return the wrong field
|
2023-08-24 14:32:12 -05:00
|
|
|
--> $DIR/misnamed_getters.rs:52:5
|
2022-12-01 11:29:38 -06:00
|
|
|
|
|
|
|
|
LL | / unsafe fn a_mut(&mut self) -> &mut u8 {
|
2023-08-24 14:32:12 -05:00
|
|
|
LL | |
|
2022-12-01 11:29:38 -06:00
|
|
|
LL | | &mut self.b
|
|
|
|
| | ----------- help: consider using: `&mut self.a`
|
|
|
|
LL | | }
|
|
|
|
| |_____^
|
|
|
|
|
|
|
|
error: getter function appears to return the wrong field
|
2023-08-24 14:32:12 -05:00
|
|
|
--> $DIR/misnamed_getters.rs:57:5
|
2022-12-01 11:29:38 -06:00
|
|
|
|
|
|
|
|
LL | / unsafe fn b(self) -> u8 {
|
2023-08-24 14:32:12 -05:00
|
|
|
LL | |
|
2022-12-01 11:29:38 -06:00
|
|
|
LL | | self.a
|
|
|
|
| | ------ help: consider using: `self.b`
|
|
|
|
LL | | }
|
|
|
|
| |_____^
|
|
|
|
|
|
|
|
error: getter function appears to return the wrong field
|
2023-08-24 14:32:12 -05:00
|
|
|
--> $DIR/misnamed_getters.rs:62:5
|
2022-12-01 11:29:38 -06:00
|
|
|
|
|
|
|
|
LL | / unsafe fn b_mut(&mut self) -> &mut u8 {
|
2023-08-24 14:32:12 -05:00
|
|
|
LL | |
|
2022-12-01 11:29:38 -06:00
|
|
|
LL | | &mut self.a
|
|
|
|
| | ----------- help: consider using: `&mut self.b`
|
|
|
|
LL | | }
|
|
|
|
| |_____^
|
|
|
|
|
|
|
|
error: getter function appears to return the wrong field
|
2023-08-24 14:32:12 -05:00
|
|
|
--> $DIR/misnamed_getters.rs:75:5
|
2022-12-01 11:29:38 -06:00
|
|
|
|
|
|
|
|
LL | / unsafe fn a_unchecked(&self) -> &u8 {
|
2023-08-24 14:32:12 -05:00
|
|
|
LL | |
|
2022-12-01 11:29:38 -06:00
|
|
|
LL | | &self.b
|
|
|
|
| | ------- help: consider using: `&self.a`
|
|
|
|
LL | | }
|
|
|
|
| |_____^
|
|
|
|
|
|
|
|
error: getter function appears to return the wrong field
|
2023-08-24 14:32:12 -05:00
|
|
|
--> $DIR/misnamed_getters.rs:79:5
|
2022-12-01 11:29:38 -06:00
|
|
|
|
|
|
|
|
LL | / unsafe fn a_unchecked_mut(&mut self) -> &mut u8 {
|
2023-08-24 14:32:12 -05:00
|
|
|
LL | |
|
2022-12-01 11:29:38 -06:00
|
|
|
LL | | &mut self.b
|
|
|
|
| | ----------- help: consider using: `&mut self.a`
|
|
|
|
LL | | }
|
|
|
|
| |_____^
|
|
|
|
|
|
|
|
error: getter function appears to return the wrong field
|
2023-08-24 14:32:12 -05:00
|
|
|
--> $DIR/misnamed_getters.rs:84:5
|
2022-12-01 11:29:38 -06:00
|
|
|
|
|
|
|
|
LL | / unsafe fn b_unchecked(self) -> u8 {
|
2023-08-24 14:32:12 -05:00
|
|
|
LL | |
|
2022-12-01 11:29:38 -06:00
|
|
|
LL | | self.a
|
|
|
|
| | ------ help: consider using: `self.b`
|
|
|
|
LL | | }
|
|
|
|
| |_____^
|
|
|
|
|
|
|
|
error: getter function appears to return the wrong field
|
2023-08-24 14:32:12 -05:00
|
|
|
--> $DIR/misnamed_getters.rs:89:5
|
2022-12-01 11:29:38 -06:00
|
|
|
|
|
|
|
|
LL | / unsafe fn b_unchecked_mut(&mut self) -> &mut u8 {
|
2023-08-24 14:32:12 -05:00
|
|
|
LL | |
|
2022-12-01 11:29:38 -06:00
|
|
|
LL | | &mut self.a
|
|
|
|
| | ----------- help: consider using: `&mut self.b`
|
|
|
|
LL | | }
|
|
|
|
| |_____^
|
|
|
|
|
|
|
|
error: getter function appears to return the wrong field
|
2023-08-24 14:32:12 -05:00
|
|
|
--> $DIR/misnamed_getters.rs:122:5
|
2022-12-01 11:29:38 -06:00
|
|
|
|
|
|
|
|
LL | / fn a(&self) -> &u8 {
|
2023-08-24 14:32:12 -05:00
|
|
|
LL | |
|
2022-12-01 11:29:38 -06:00
|
|
|
LL | | &self.b
|
|
|
|
| | ------- help: consider using: `&self.a`
|
|
|
|
LL | | }
|
|
|
|
| |_____^
|
|
|
|
|
|
|
|
error: getter function appears to return the wrong field
|
2023-08-24 14:32:12 -05:00
|
|
|
--> $DIR/misnamed_getters.rs:126:5
|
2022-12-01 11:29:38 -06:00
|
|
|
|
|
|
|
|
LL | / fn a_mut(&mut self) -> &mut u8 {
|
2023-08-24 14:32:12 -05:00
|
|
|
LL | |
|
2022-12-01 11:29:38 -06:00
|
|
|
LL | | &mut self.b
|
|
|
|
| | ----------- help: consider using: `&mut self.a`
|
|
|
|
LL | | }
|
|
|
|
| |_____^
|
|
|
|
|
|
|
|
error: getter function appears to return the wrong field
|
2023-08-24 14:32:12 -05:00
|
|
|
--> $DIR/misnamed_getters.rs:131:5
|
2022-12-01 11:29:38 -06:00
|
|
|
|
|
|
|
|
LL | / fn d(&self) -> &u8 {
|
2023-08-24 14:32:12 -05:00
|
|
|
LL | |
|
2022-12-01 11:29:38 -06:00
|
|
|
LL | | &self.b
|
|
|
|
| | ------- help: consider using: `&self.d`
|
|
|
|
LL | | }
|
|
|
|
| |_____^
|
|
|
|
|
|
|
|
error: getter function appears to return the wrong field
|
2023-08-24 14:32:12 -05:00
|
|
|
--> $DIR/misnamed_getters.rs:135:5
|
2022-12-01 11:29:38 -06:00
|
|
|
|
|
|
|
|
LL | / fn d_mut(&mut self) -> &mut u8 {
|
2023-08-24 14:32:12 -05:00
|
|
|
LL | |
|
2022-12-01 11:29:38 -06:00
|
|
|
LL | | &mut self.b
|
|
|
|
| | ----------- help: consider using: `&mut self.d`
|
|
|
|
LL | | }
|
|
|
|
| |_____^
|
|
|
|
|
|
|
|
error: aborting due to 18 previous errors
|
|
|
|
|