blob: 9da21eb6b29b82ff9ce6283373d2f1819c8f0ebb (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
|
// run-rustfix
#![warn(clippy::needless_arbitrary_self_type)]
#![allow(unused_mut, clippy::needless_lifetimes)]
pub enum ValType {
A,
B,
}
impl ValType {
pub fn bad(self) {
unimplemented!();
}
pub fn good(self) {
unimplemented!();
}
pub fn mut_bad(mut self) {
unimplemented!();
}
pub fn mut_good(mut self) {
unimplemented!();
}
pub fn ref_bad(&self) {
unimplemented!();
}
pub fn ref_good(&self) {
unimplemented!();
}
pub fn ref_bad_with_lifetime<'a>(&'a self) {
unimplemented!();
}
pub fn ref_good_with_lifetime<'a>(&'a self) {
unimplemented!();
}
pub fn mut_ref_bad(&mut self) {
unimplemented!();
}
pub fn mut_ref_good(&mut self) {
unimplemented!();
}
pub fn mut_ref_bad_with_lifetime<'a>(&'a mut self) {
unimplemented!();
}
pub fn mut_ref_good_with_lifetime<'a>(&'a mut self) {
unimplemented!();
}
pub fn mut_ref_mut_good(mut self: &mut Self) {
unimplemented!();
}
pub fn mut_ref_mut_ref_good(self: &&mut &mut Self) {
unimplemented!();
}
}
fn main() {}
|