2021-03-17 14:52:14 +00:00
|
|
|
error: methods with the following characteristics: (`to_*` and `self type is not Copy`) usually take self by reference
|
2021-03-12 07:47:15 +00:00
|
|
|
--> $DIR/wrong_self_conventions_mut.rs:15:24
|
|
|
|
|
|
|
|
|
LL | pub fn to_many(&mut self) -> Option<&mut [T]> {
|
|
|
|
| ^^^^^^^^^
|
|
|
|
|
|
|
|
|
= note: `-D clippy::wrong-self-convention` implied by `-D warnings`
|
|
|
|
= help: consider choosing a less ambiguous name
|
|
|
|
|
2021-03-17 14:52:14 +00:00
|
|
|
error: methods with the following characteristics: (`to_*` and `*_mut`) usually take self by mutable reference
|
2021-03-12 07:47:15 +00:00
|
|
|
--> $DIR/wrong_self_conventions_mut.rs:23:28
|
|
|
|
|
|
|
|
|
LL | pub fn to_many_mut(&self) -> Option<&[T]> {
|
|
|
|
| ^^^^^
|
|
|
|
|
|
|
|
|
= help: consider choosing a less ambiguous name
|
|
|
|
|
|
|
|
error: aborting due to 2 previous errors
|
|
|
|
|