1 #![warn(clippy::wrong_self_convention)]
9 fn to_thing(&self) -> Thing;
13 // don't trigger, e.g. `ToString` from `std` requires `&self`
14 fn to_thing(&self) -> Thing {
20 fn to_u64(self) -> u64;
25 impl ToU64 for FooNoCopy {
26 fn to_u64(self) -> u64 {
34 fn from_usize(x: usize) -> Self;
38 fn from_usize(x: usize) -> Self {
48 // don't trigger (`s` is not `self`)
49 pub fn from_be(s: Self) -> Self {
54 pub fn from_be_self(self) -> Self {
55 S(i32::from_be(self.0))
60 // don't trigger (`s` is not `self`)
61 fn from_be(s: Self) -> Self;
63 fn from_be_self(self) -> Self;
67 fn as_byte_slice(slice: &[Self]) -> &[u8];
72 struct CellLikeThing<T>(T);
74 impl<T> CellLikeThing<T> {
76 fn into_inner(this: Self) -> T {
81 impl<T> std::ops::Deref for CellLikeThing<T> {
84 fn deref(&self) -> &T {
96 pub fn as_mut(self: Pin<&mut Self>) {}
98 pub fn as_other_thingy(self: Pin<&Self>) {}
100 pub fn is_other_thingy(self: Pin<&Self>) {}
102 pub fn to_mut(self: Pin<&mut Self>) {}
104 pub fn to_other_thingy(self: Pin<&Self>) {}