|
5 | 5 |
|
6 | 6 | use std::ops::{Add, Deref, Index, IndexMut}; |
7 | 7 |
|
8 | | -pub struct _Indexable { |
| 8 | +pub struct Indexable { |
9 | 9 | data: [u8; 3], |
10 | 10 | } |
11 | 11 |
|
12 | | -impl Index<usize> for _Indexable { |
| 12 | +impl Index<usize> for Indexable { |
13 | 13 | type Output = u8; |
14 | 14 |
|
15 | | - //~ MONO_ITEM fn <_Indexable as std::ops::Index<usize>>::index |
| 15 | + //~ MONO_ITEM fn <Indexable as std::ops::Index<usize>>::index |
16 | 16 | fn index(&self, index: usize) -> &Self::Output { |
17 | 17 | if index >= 3 { &self.data[0] } else { &self.data[index] } |
18 | 18 | } |
19 | 19 | } |
20 | 20 |
|
21 | | -impl IndexMut<usize> for _Indexable { |
22 | | - //~ MONO_ITEM fn <_Indexable as std::ops::IndexMut<usize>>::index_mut |
| 21 | +impl IndexMut<usize> for Indexable { |
| 22 | + //~ MONO_ITEM fn <Indexable as std::ops::IndexMut<usize>>::index_mut |
23 | 23 | fn index_mut(&mut self, index: usize) -> &mut Self::Output { |
24 | 24 | if index >= 3 { &mut self.data[0] } else { &mut self.data[index] } |
25 | 25 | } |
26 | 26 | } |
27 | 27 |
|
28 | | -//~ MONO_ITEM fn <_Equatable as std::cmp::PartialEq>::eq |
29 | | -//~ MONO_ITEM fn <_Equatable as std::cmp::PartialEq>::ne |
| 28 | +//~ MONO_ITEM fn <Equatable as std::cmp::PartialEq>::eq |
| 29 | +//~ MONO_ITEM fn <Equatable as std::cmp::PartialEq>::ne |
30 | 30 | #[derive(PartialEq)] |
31 | | -pub struct _Equatable(u32); |
| 31 | +pub struct Equatable(u32); |
32 | 32 |
|
33 | | -impl Add<u32> for _Equatable { |
| 33 | +impl Add<u32> for Equatable { |
34 | 34 | type Output = u32; |
35 | 35 |
|
36 | | - //~ MONO_ITEM fn <_Equatable as std::ops::Add<u32>>::add |
| 36 | + //~ MONO_ITEM fn <Equatable as std::ops::Add<u32>>::add |
37 | 37 | fn add(self, rhs: u32) -> u32 { |
38 | 38 | self.0 + rhs |
39 | 39 | } |
40 | 40 | } |
41 | 41 |
|
42 | | -impl Deref for _Equatable { |
| 42 | +impl Deref for Equatable { |
43 | 43 | type Target = u32; |
44 | 44 |
|
45 | | - //~ MONO_ITEM fn <_Equatable as std::ops::Deref>::deref |
| 45 | + //~ MONO_ITEM fn <Equatable as std::ops::Deref>::deref |
46 | 46 | fn deref(&self) -> &Self::Target { |
47 | 47 | &self.0 |
48 | 48 | } |
|
0 commit comments