Skip to content

Commit

Permalink
Fix unused_self.
Browse files Browse the repository at this point in the history
  • Loading branch information
kpreid committed Mar 4, 2025
1 parent 4759a86 commit 32fce15
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions clippy_lints/src/item_name_repetitions.rs
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,7 @@ impl ItemNameRepetitions {
check_enum_end(cx, item_name, var);
}

self.check_enum_common_affix(cx, item, def);
Self::check_enum_common_affix(cx, item, def);
}

/// Lint the names of struct fields against the name of the struct.
Expand All @@ -225,7 +225,7 @@ impl ItemNameRepetitions {
self.check_struct_common_affix(cx, item, fields);
}

fn check_enum_common_affix(&self, cx: &LateContext<'_>, item: &Item<'_>, def: &EnumDef<'_>) {
fn check_enum_common_affix(cx: &LateContext<'_>, item: &Item<'_>, def: &EnumDef<'_>) {
let first = match def.variants.first() {
Some(variant) => variant.ident.name.as_str(),
None => return,
Expand Down

0 comments on commit 32fce15

Please sign in to comment.