Unnamed repository; edit this file 'description' to name the repository.
Diffstat (limited to 'crates/ide_assists/src/handlers/merge_match_arms.rs')
-rw-r--r--crates/ide_assists/src/handlers/merge_match_arms.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/crates/ide_assists/src/handlers/merge_match_arms.rs b/crates/ide_assists/src/handlers/merge_match_arms.rs
index 622ead81f1..83d7f0338a 100644
--- a/crates/ide_assists/src/handlers/merge_match_arms.rs
+++ b/crates/ide_assists/src/handlers/merge_match_arms.rs
@@ -40,7 +40,7 @@ pub(crate) fn merge_match_arms(acc: &mut Assists, ctx: &AssistContext) -> Option
}
let current_expr = current_arm.expr()?;
let current_text_range = current_arm.syntax().text_range();
- let current_arm_types = get_arm_types(&ctx, &current_arm);
+ let current_arm_types = get_arm_types(ctx, &current_arm);
// We check if the following match arms match this one. We could, but don't,
// compare to the previous match arm as well.
@@ -99,7 +99,7 @@ fn are_same_types(
arm: &ast::MatchArm,
ctx: &AssistContext,
) -> bool {
- let arm_types = get_arm_types(&ctx, &arm);
+ let arm_types = get_arm_types(ctx, arm);
for (other_arm_type_name, other_arm_type) in arm_types {
match (current_arm_types.get(&other_arm_type_name), other_arm_type) {
(Some(Some(current_arm_type)), Some(other_arm_type))
@@ -163,7 +163,7 @@ fn get_arm_types(
}
}
- recurse(&mut mapping, &context, &arm.pat());
+ recurse(&mut mapping, context, &arm.pat());
mapping
}